Package org.drip.spline.grid
Class AggregatedSpan
java.lang.Object
org.drip.spline.grid.AggregatedSpan
- All Implemented Interfaces:
Span
public class AggregatedSpan extends java.lang.Object implements Span
AggregatedSpan implements the Span interface. Here response from an array of spans whose responses
are aggregated by their weights.
- Author:
- Lakshmi Krishnamurthy
-
Constructor Summary
Constructors Constructor Description AggregatedSpan(java.util.List<Span> spanList, java.util.List<java.lang.Double> weightList)AggregatedSpan Constructor -
Method Summary
Modifier and Type Method Description booleanaddStretch(MultiSegmentSequence multiSegmentSequence)Add a Stretch to the SpandoublecalcResponseValue(double predictorOrdinate)Compute the Response from the containing StretchesdoublecalcResponseValueDerivative(double predictorOrdinate, int order)Compute the Response Value Derivative from the containing Stretchesjava.lang.StringdisplayString()Display the Span Edge CoordinatesMultiSegmentSequencegetContainingStretch(double predictorOrdinate)Retrieve the first Stretch that contains the Predictor OrdinateMultiSegmentSequencegetStretch(java.lang.String name)Retrieve the Stretch by Namebooleanin(double predictorOrdinate)Check if the Predictor Ordinate is in the Stretch RangebooleanisMergeState(double predictorOrdinate, LatentStateLabel latentStateLabel)Indicate if the specified Label is part of the Merge State at the specified Predictor OrdinateWengertJacobianjackDResponseDManifestMeasure(java.lang.String manifestMeasure, double predictorOrdinate, int order)Calculate the Response Derivative to the Manifest Measure at the specified Ordinatedoubleleft()Retrieve the Left Span Edgedoubleright()Retrieve the Right Span EdgeMethods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Constructor Details
-
AggregatedSpan
public AggregatedSpan(java.util.List<Span> spanList, java.util.List<java.lang.Double> weightList) throws java.lang.ExceptionAggregatedSpan Constructor- Parameters:
spanList- List of SpansweightList- List of Weights- Throws:
java.lang.Exception- Thrown if the Inputs are Invalid
-
-
Method Details
-
addStretch
Description copied from interface:SpanAdd a Stretch to the Span- Specified by:
addStretchin interfaceSpan- Parameters:
multiSegmentSequence- Stretch to be added- Returns:
- TRUE - Stretch added successfully
-
getContainingStretch
Description copied from interface:SpanRetrieve the first Stretch that contains the Predictor Ordinate- Specified by:
getContainingStretchin interfaceSpan- Parameters:
predictorOrdinate- The Predictor Ordinate- Returns:
- The containing Stretch
-
getStretch
Description copied from interface:SpanRetrieve the Stretch by Name- Specified by:
getStretchin interfaceSpan- Parameters:
name- The Stretch Name- Returns:
- The Stretch
-
left
public double left() throws java.lang.ExceptionDescription copied from interface:SpanRetrieve the Left Span Edge -
right
public double right() throws java.lang.ExceptionDescription copied from interface:SpanRetrieve the Right Span Edge -
calcResponseValue
public double calcResponseValue(double predictorOrdinate) throws java.lang.ExceptionDescription copied from interface:SpanCompute the Response from the containing Stretches- Specified by:
calcResponseValuein interfaceSpan- Parameters:
predictorOrdinate- The Predictor Ordinate- Returns:
- The Response
- Throws:
java.lang.Exception- Thrown if the Inputs are invalid
-
calcResponseValueDerivative
public double calcResponseValueDerivative(double predictorOrdinate, int order) throws java.lang.ExceptionDescription copied from interface:SpanCompute the Response Value Derivative from the containing Stretches- Specified by:
calcResponseValueDerivativein interfaceSpan- Parameters:
predictorOrdinate- The Predictor Ordinateorder- Order of the Derivative to be calculated- Returns:
- The Response Value Derivative
- Throws:
java.lang.Exception- Thrown if the Inputs are invalid
-
isMergeState
Description copied from interface:SpanIndicate if the specified Label is part of the Merge State at the specified Predictor Ordinate- Specified by:
isMergeStatein interfaceSpan- Parameters:
predictorOrdinate- The Predictor OrdinatelatentStateLabel- Merge State Label- Returns:
- TRUE - The specified Label is part of the Merge State at the specified Predictor Ordinate
-
jackDResponseDManifestMeasure
public WengertJacobian jackDResponseDManifestMeasure(java.lang.String manifestMeasure, double predictorOrdinate, int order)Description copied from interface:SpanCalculate the Response Derivative to the Manifest Measure at the specified Ordinate- Specified by:
jackDResponseDManifestMeasurein interfaceSpan- Parameters:
manifestMeasure- Manifest Measure whose Sensitivity is soughtpredictorOrdinate- Predictor Ordinateorder- Order of Derivative desired- Returns:
- Jacobian of the Response Derivative to the Manifest Measure at the Ordinate
-
in
public boolean in(double predictorOrdinate) throws java.lang.ExceptionDescription copied from interface:SpanCheck if the Predictor Ordinate is in the Stretch Range -
displayString
public java.lang.String displayString()Description copied from interface:SpanDisplay the Span Edge Coordinates- Specified by:
displayStringin interfaceSpan- Returns:
- The Edge Coordinates String
-