public final class SabrIborCapletFloorletVolatilityCalibrationDefinition extends Object implements IborCapletFloorletVolatilityDefinition, org.joda.beans.ImmutableBean, Serializable
This definition is used with SabrIborCapletFloorletVolatilityCalibrator.
The term structure of SABR model parameters is calibrated to cap volatilities.
The SABR parameters are represented by NodalCurve and the node positions on the curves are flexible.
Either rho or beta must be fixed.
Then the calibration is computed in terms of the other three SABR parameter curves.
The resulting volatilities object will be SabrParametersIborCapletFloorletVolatilities.
| Modifier and Type | Class and Description |
|---|---|
static class |
SabrIborCapletFloorletVolatilityCalibrationDefinition.Builder
The bean-builder for
SabrIborCapletFloorletVolatilityCalibrationDefinition. |
static class |
SabrIborCapletFloorletVolatilityCalibrationDefinition.Meta
The meta-bean for
SabrIborCapletFloorletVolatilityCalibrationDefinition. |
| Modifier and Type | Method and Description |
|---|---|
static SabrIborCapletFloorletVolatilityCalibrationDefinition.Builder |
builder()
Returns a builder used to create an instance of the bean.
|
DoubleArray |
createFullInitialValues()
Create initial values for all the curve parameters.
|
com.opengamma.strata.math.impl.minimization.ParameterLimitsTransform[] |
createFullTransform(com.opengamma.strata.math.impl.minimization.ParameterLimitsTransform[] transform)
Creates the transformation definition for all the curve parameters.
|
SurfaceMetadata |
createMetadata(RawOptionData capFloorData)
Creates surface metadata.
|
List<Curve> |
createSabrParameterCurve(List<CurveMetadata> metadata,
DoubleArray nodeValues)
Creates the parameter curves with parameter node values.
|
ImmutableList<CurveMetadata> |
createSabrParameterMetadata()
Creates curve metadata for SABR parameters.
|
boolean |
equals(Object obj) |
Optional<Curve> |
getBetaCurve()
Gets the beta (elasticity) curve.
|
DayCount |
getDayCount()
Gets the day count to measure the time in the expiry dimension.
|
CurveExtrapolator |
getExtrapolatorLeft()
Gets the left extrapolator for the SABR parameters.
|
CurveExtrapolator |
getExtrapolatorRight()
Gets the right extrapolator for the SABR parameters.
|
IborIndex |
getIndex()
Gets the Ibor index for which the data is valid.
|
DoubleArray |
getInitialParameters()
Gets the initial parameter values used in calibration.
|
CurveInterpolator |
getInterpolator()
Gets the interpolator for the SABR parameters.
|
IborCapletFloorletVolatilitiesName |
getName()
Gets the name of the volatilities.
|
ImmutableList<DoubleArray> |
getParameterCurveNodes()
Gets the nodes of SABR parameter curves.
|
Optional<Curve> |
getRhoCurve()
Gets the rho (correlation) curve.
|
SabrVolatilityFormula |
getSabrVolatilityFormula()
Gets the SABR formula.
|
Curve |
getShiftCurve()
Gets the shift curve.
|
int |
hashCode() |
static SabrIborCapletFloorletVolatilityCalibrationDefinition.Meta |
meta()
The meta-bean for
SabrIborCapletFloorletVolatilityCalibrationDefinition. |
SabrIborCapletFloorletVolatilityCalibrationDefinition.Meta |
metaBean() |
static SabrIborCapletFloorletVolatilityCalibrationDefinition |
ofFixedBeta(IborCapletFloorletVolatilitiesName name,
IborIndex index,
DayCount dayCount,
DoubleArray alphaCurveNodes,
DoubleArray rhoCurveNodes,
DoubleArray nuCurveNodes,
DoubleArray initialParameters,
CurveInterpolator interpolator,
CurveExtrapolator extrapolatorLeft,
CurveExtrapolator extrapolatorRight,
SabrVolatilityFormula sabrVolatilityFormula)
Obtains an instance with fixed beta, zero shift and initial values.
|
static SabrIborCapletFloorletVolatilityCalibrationDefinition |
ofFixedBeta(IborCapletFloorletVolatilitiesName name,
IborIndex index,
DayCount dayCount,
double beta,
DoubleArray alphaCurveNodes,
DoubleArray rhoCurveNodes,
DoubleArray nuCurveNodes,
CurveInterpolator interpolator,
CurveExtrapolator extrapolatorLeft,
CurveExtrapolator extrapolatorRight,
SabrVolatilityFormula sabrVolatilityFormula)
Obtains an instance with fixed beta and zero shift.
|
static SabrIborCapletFloorletVolatilityCalibrationDefinition |
ofFixedBeta(IborCapletFloorletVolatilitiesName name,
IborIndex index,
DayCount dayCount,
double shift,
DoubleArray alphaCurveNodes,
DoubleArray rhoCurveNodes,
DoubleArray nuCurveNodes,
DoubleArray initialParameters,
CurveInterpolator interpolator,
CurveExtrapolator extrapolatorLeft,
CurveExtrapolator extrapolatorRight,
SabrVolatilityFormula sabrVolatilityFormula)
Obtains an instance with fixed beta, nonzero shift and initial values.
|
static SabrIborCapletFloorletVolatilityCalibrationDefinition |
ofFixedBeta(IborCapletFloorletVolatilitiesName name,
IborIndex index,
DayCount dayCount,
double beta,
double shift,
DoubleArray alphaCurveNodes,
DoubleArray rhoCurveNodes,
DoubleArray nuCurveNodes,
CurveInterpolator interpolator,
CurveExtrapolator extrapolatorLeft,
CurveExtrapolator extrapolatorRight,
SabrVolatilityFormula sabrVolatilityFormula)
Obtains an instance with fixed beta and nonzero shift.
|
static SabrIborCapletFloorletVolatilityCalibrationDefinition |
ofFixedRho(IborCapletFloorletVolatilitiesName name,
IborIndex index,
DayCount dayCount,
DoubleArray alphaCurveNodes,
DoubleArray betaCurveNodes,
DoubleArray nuCurveNodes,
DoubleArray initialParameters,
CurveInterpolator interpolator,
CurveExtrapolator extrapolatorLeft,
CurveExtrapolator extrapolatorRight,
SabrVolatilityFormula sabrVolatilityFormula)
Obtains an instance with fixed rho, zero shift and initial values.
|
static SabrIborCapletFloorletVolatilityCalibrationDefinition |
ofFixedRho(IborCapletFloorletVolatilitiesName name,
IborIndex index,
DayCount dayCount,
double rho,
DoubleArray alphaCurveNodes,
DoubleArray betaCurveNodes,
DoubleArray nuCurveNodes,
CurveInterpolator interpolator,
CurveExtrapolator extrapolatorLeft,
CurveExtrapolator extrapolatorRight,
SabrVolatilityFormula sabrVolatilityFormula)
Obtains an instance with fixed rho and zero shift.
|
static SabrIborCapletFloorletVolatilityCalibrationDefinition |
ofFixedRho(IborCapletFloorletVolatilitiesName name,
IborIndex index,
DayCount dayCount,
double shift,
DoubleArray alphaCurveNodes,
DoubleArray betaCurveNodes,
DoubleArray nuCurveNodes,
DoubleArray initialParameters,
CurveInterpolator interpolator,
CurveExtrapolator extrapolatorLeft,
CurveExtrapolator extrapolatorRight,
SabrVolatilityFormula sabrVolatilityFormula)
Obtains an instance with fixed rho, nonzero shift and initial values.
|
static SabrIborCapletFloorletVolatilityCalibrationDefinition |
ofFixedRho(IborCapletFloorletVolatilitiesName name,
IborIndex index,
DayCount dayCount,
double rho,
double shift,
DoubleArray alphaCurveNodes,
DoubleArray betaCurveNodes,
DoubleArray nuCurveNodes,
CurveInterpolator interpolator,
CurveExtrapolator extrapolatorLeft,
CurveExtrapolator extrapolatorRight,
SabrVolatilityFormula sabrVolatilityFormula)
Obtains an instance with fixed rho and nonzero shift.
|
SabrIborCapletFloorletVolatilityCalibrationDefinition.Builder |
toBuilder()
Returns a builder that allows this bean to be mutated.
|
String |
toString() |
clone, finalize, getClass, notify, notifyAll, wait, wait, waitcreateCappublic static SabrIborCapletFloorletVolatilityCalibrationDefinition ofFixedBeta(IborCapletFloorletVolatilitiesName name, IborIndex index, DayCount dayCount, double beta, double shift, DoubleArray alphaCurveNodes, DoubleArray rhoCurveNodes, DoubleArray nuCurveNodes, CurveInterpolator interpolator, CurveExtrapolator extrapolatorLeft, CurveExtrapolator extrapolatorRight, SabrVolatilityFormula sabrVolatilityFormula)
The beta and shift are constant in time. The default initial values will be used in the calibration.
name - the name of volatilitiesindex - the Ibor indexdayCount - the day countbeta - the betashift - the shiftalphaCurveNodes - the alpha curve nodesrhoCurveNodes - the rho curve nodesnuCurveNodes - the nu curve nodesinterpolator - the interpolatorextrapolatorLeft - the left extrapolatorextrapolatorRight - the right extrapolatorsabrVolatilityFormula - the SABR formulapublic static SabrIborCapletFloorletVolatilityCalibrationDefinition ofFixedBeta(IborCapletFloorletVolatilitiesName name, IborIndex index, DayCount dayCount, double beta, DoubleArray alphaCurveNodes, DoubleArray rhoCurveNodes, DoubleArray nuCurveNodes, CurveInterpolator interpolator, CurveExtrapolator extrapolatorLeft, CurveExtrapolator extrapolatorRight, SabrVolatilityFormula sabrVolatilityFormula)
The default initial values will be used in the calibration.
name - the name of volatilitiesindex - the Ibor indexdayCount - the day countbeta - the betaalphaCurveNodes - the alpha curve nodesrhoCurveNodes - the rho curve nodesnuCurveNodes - the nu curve nodesinterpolator - the interpolatorextrapolatorLeft - the left extrapolatorextrapolatorRight - the right extrapolatorsabrVolatilityFormula - the SABR formulapublic static SabrIborCapletFloorletVolatilityCalibrationDefinition ofFixedBeta(IborCapletFloorletVolatilitiesName name, IborIndex index, DayCount dayCount, double shift, DoubleArray alphaCurveNodes, DoubleArray rhoCurveNodes, DoubleArray nuCurveNodes, DoubleArray initialParameters, CurveInterpolator interpolator, CurveExtrapolator extrapolatorLeft, CurveExtrapolator extrapolatorRight, SabrVolatilityFormula sabrVolatilityFormula)
The beta and shift are constant in time.
name - the name of volatilitiesindex - the Ibor indexdayCount - the day countshift - the shiftalphaCurveNodes - the alpha curve nodesrhoCurveNodes - the rho curve nodesnuCurveNodes - the nu curve nodesinitialParameters - the initial parametersinterpolator - the interpolatorextrapolatorLeft - the left extrapolatorextrapolatorRight - the right extrapolatorsabrVolatilityFormula - the SABR formulapublic static SabrIborCapletFloorletVolatilityCalibrationDefinition ofFixedBeta(IborCapletFloorletVolatilitiesName name, IborIndex index, DayCount dayCount, DoubleArray alphaCurveNodes, DoubleArray rhoCurveNodes, DoubleArray nuCurveNodes, DoubleArray initialParameters, CurveInterpolator interpolator, CurveExtrapolator extrapolatorLeft, CurveExtrapolator extrapolatorRight, SabrVolatilityFormula sabrVolatilityFormula)
The beta and shift are constant in time.
name - the name of volatilitiesindex - the Ibor indexdayCount - the day countalphaCurveNodes - the alpha curve nodesrhoCurveNodes - the rho curve nodesnuCurveNodes - the nu curve nodesinitialParameters - the initial parametersinterpolator - the interpolatorextrapolatorLeft - the left extrapolatorextrapolatorRight - the right extrapolatorsabrVolatilityFormula - the SABR formulapublic static SabrIborCapletFloorletVolatilityCalibrationDefinition ofFixedRho(IborCapletFloorletVolatilitiesName name, IborIndex index, DayCount dayCount, double rho, double shift, DoubleArray alphaCurveNodes, DoubleArray betaCurveNodes, DoubleArray nuCurveNodes, CurveInterpolator interpolator, CurveExtrapolator extrapolatorLeft, CurveExtrapolator extrapolatorRight, SabrVolatilityFormula sabrVolatilityFormula)
The rho and shift are constant in time. The default initial values will be used in the calibration.
name - the name of volatilitiesindex - the Ibor indexdayCount - the day countrho - the rhoshift - the shiftalphaCurveNodes - the alpha curve nodesbetaCurveNodes - the beta curve nodesnuCurveNodes - the nu curve nodesinterpolator - the interpolatorextrapolatorLeft - the left extrapolatorextrapolatorRight - the right extrapolatorsabrVolatilityFormula - the SABR formulapublic static SabrIborCapletFloorletVolatilityCalibrationDefinition ofFixedRho(IborCapletFloorletVolatilitiesName name, IborIndex index, DayCount dayCount, double rho, DoubleArray alphaCurveNodes, DoubleArray betaCurveNodes, DoubleArray nuCurveNodes, CurveInterpolator interpolator, CurveExtrapolator extrapolatorLeft, CurveExtrapolator extrapolatorRight, SabrVolatilityFormula sabrVolatilityFormula)
The rho is constant in time. The default initial values will be used in the calibration.
name - the name of volatilitiesindex - the Ibor indexdayCount - the day countrho - the rhoalphaCurveNodes - the alpha curve nodesbetaCurveNodes - the beta curve nodesnuCurveNodes - the nu curve nodesinterpolator - the interpolatorextrapolatorLeft - the left extrapolatorextrapolatorRight - the right extrapolatorsabrVolatilityFormula - the SABR formulapublic static SabrIborCapletFloorletVolatilityCalibrationDefinition ofFixedRho(IborCapletFloorletVolatilitiesName name, IborIndex index, DayCount dayCount, double shift, DoubleArray alphaCurveNodes, DoubleArray betaCurveNodes, DoubleArray nuCurveNodes, DoubleArray initialParameters, CurveInterpolator interpolator, CurveExtrapolator extrapolatorLeft, CurveExtrapolator extrapolatorRight, SabrVolatilityFormula sabrVolatilityFormula)
The rho and shift are constant in time.
name - the name of volatilitiesindex - the Ibor indexdayCount - the day countshift - the shiftalphaCurveNodes - the alpha curve nodesbetaCurveNodes - the beta curve nodesnuCurveNodes - the nu curve nodesinitialParameters - the initial parametersinterpolator - the interpolatorextrapolatorLeft - the left extrapolatorextrapolatorRight - the right extrapolatorsabrVolatilityFormula - the SABR formulapublic static SabrIborCapletFloorletVolatilityCalibrationDefinition ofFixedRho(IborCapletFloorletVolatilitiesName name, IborIndex index, DayCount dayCount, DoubleArray alphaCurveNodes, DoubleArray betaCurveNodes, DoubleArray nuCurveNodes, DoubleArray initialParameters, CurveInterpolator interpolator, CurveExtrapolator extrapolatorLeft, CurveExtrapolator extrapolatorRight, SabrVolatilityFormula sabrVolatilityFormula)
The rho is constant in time.
name - the name of volatilitiesindex - the Ibor indexdayCount - the day countalphaCurveNodes - the alpha curve nodesbetaCurveNodes - the beta curve nodesnuCurveNodes - the nu curve nodesinitialParameters - the initial parametersinterpolator - the interpolatorextrapolatorLeft - the left extrapolatorextrapolatorRight - the right extrapolatorsabrVolatilityFormula - the SABR formulapublic SurfaceMetadata createMetadata(RawOptionData capFloorData)
IborCapletFloorletVolatilityDefinitioncreateMetadata in interface IborCapletFloorletVolatilityDefinitioncapFloorData - the cap/floor datapublic ImmutableList<CurveMetadata> createSabrParameterMetadata()
The metadata in the list are ordered as alpha, beta, rho, then nu.
public List<Curve> createSabrParameterCurve(List<CurveMetadata> metadata, DoubleArray nodeValues)
The node values must be combined nodes ordered as alpha, beta (if beta is not fixed), rho (if rho is not fixed), then nu.
The returned curves are ordered in the same way.
If the beta is fixed, betaCurve is returned as the second element.
If the rho is fixed, rhoCurve is returned as the third element.
metadata - the metadatanodeValues - the parameter node valuespublic com.opengamma.strata.math.impl.minimization.ParameterLimitsTransform[] createFullTransform(com.opengamma.strata.math.impl.minimization.ParameterLimitsTransform[] transform)
The elements in transform must be ordered as alpha, beta, rho, then nu.
transform - the transformpublic DoubleArray createFullInitialValues()
public static SabrIborCapletFloorletVolatilityCalibrationDefinition.Meta meta()
SabrIborCapletFloorletVolatilityCalibrationDefinition.public static SabrIborCapletFloorletVolatilityCalibrationDefinition.Builder builder()
public SabrIborCapletFloorletVolatilityCalibrationDefinition.Meta metaBean()
metaBean in interface org.joda.beans.Beanpublic IborCapletFloorletVolatilitiesName getName()
getName in interface IborCapletFloorletVolatilityDefinitionpublic IborIndex getIndex()
getIndex in interface IborCapletFloorletVolatilityDefinitionpublic DayCount getDayCount()
getDayCount in interface IborCapletFloorletVolatilityDefinitionpublic Optional<Curve> getBetaCurve()
This represents the beta parameter of SABR model.
The beta will be treated as one of the calibration parameters if this field is not specified.
Either betaCurve or rhoCurve must be present.
public Optional<Curve> getRhoCurve()
This represents the rho parameter of SABR model.
The rho will be treated as one of the calibration parameters if this field is not specified.
Either betaCurve or rhoCurve must be present.
public Curve getShiftCurve()
This represents the shift parameter of shifted SABR model.
The shift is set to be zero if this field is not specified.
public ImmutableList<DoubleArray> getParameterCurveNodes()
The size of the list must be 4, ordered as alpha, beta, rho and nu.
If the number of nodes is greater than 1, the curve will be created with CurveInterpolator and
CurveExtrapolator specified below. Otherwise, ConstantNodalCurve will be created.
public DoubleArray getInitialParameters()
Default values will be used if not specified. The size of this field must be 4, ordered as alpha, beta, rho and nu.
public CurveInterpolator getInterpolator()
public CurveExtrapolator getExtrapolatorLeft()
The flat extrapolation is used if not specified.
public CurveExtrapolator getExtrapolatorRight()
The flat extrapolation is used if not specified.
public SabrVolatilityFormula getSabrVolatilityFormula()
public SabrIborCapletFloorletVolatilityCalibrationDefinition.Builder toBuilder()
Copyright 2009-Present by OpenGamma Inc. and individual contributors
Apache v2 licensed
Additional documentation can be found at strata.opengamma.io.