public abstract class AbstractCubeCalibration extends Object
buildCubeinitializeParametersapplyParameterBounds| Modifier and Type | Class and Description |
|---|---|
protected class |
AbstractCubeCalibration.SwaptionInfo
Compact identifier for the swaptions to be created during the optimization.
|
| Constructor and Description |
|---|
AbstractCubeCalibration(LocalDate referenceDate,
SwaptionDataLattice cashPayerPremiums,
SwaptionDataLattice cashReceiverPremiums,
VolatilityCubeModel model,
AnnuityMapping.AnnuityMappingType annuityMappingType)
Create the calibrator.
|
| Modifier and Type | Method and Description |
|---|---|
protected abstract double[] |
applyParameterBounds(double[] parameters)
Apply bounds to parameters.
|
protected abstract VolatilityCube |
buildCube(String name,
double[] parameters)
Build the cube from a set of parameters.
|
VolatilityCube |
calibrate(String cubeName)
Run the calibration.
|
String |
getForwardCurveName() |
double[] |
getInitialParameters() |
int |
getMaxIterations() |
VolatilityCubeModel |
getModel() |
int |
getNumberOfThreads() |
LocalDate |
getReferenceDate() |
double |
getReplicationLowerBound() |
int |
getReplicationNumberOfEvaluationPoints() |
double |
getReplicationUpperBound() |
protected abstract void |
initializeParameters()
Prepare the parameters for the start of the calibration.
|
boolean |
isReplicationUseAsOffset() |
void |
setCalibrationParameters(int maxIterations,
int numberOfThreads)
Set the parameters for calibration.
|
void |
setInitialParameters(double[] initialParameters) |
void |
setReplicationParameters(boolean useAsOffset,
double lowerBound,
double upperBound,
int numberOfEvaluationPoints)
Set the parameters for the swaption replication.
|
public AbstractCubeCalibration(LocalDate referenceDate, SwaptionDataLattice cashPayerPremiums, SwaptionDataLattice cashReceiverPremiums, VolatilityCubeModel model, AnnuityMapping.AnnuityMappingType annuityMappingType)
referenceDate - The reference date of the cube.cashPayerPremiums - The lattice containing market targets for cash settled payer swaptions. The lattice needs to be quoted in QuotingConvention.PRICE.cashReceiverPremiums - The lattice containing market targets for cash settled receiver swaptions. The lattice needs to be quoted in QuotingConvention.PRICE.model - The model providing context.annuityMappingType - The type of annuity mapping to be used for calibration.IllegalArgumentException - Triggers when data is not provided in QuotingConvention.Price.protected abstract VolatilityCube buildCube(String name, double[] parameters)
name - The name the cube will carry.parameters - The parameters of the cube as array.protected abstract void initializeParameters()
protected abstract double[] applyParameterBounds(double[] parameters)
parameters - The raw parameters of the cube as array.public VolatilityCube calibrate(String cubeName) throws SolverException
cubeName - The name of the final cube.SolverException - Thrown, when solvers fail to find suitable parameters.public void setCalibrationParameters(int maxIterations,
int numberOfThreads)
maxIterations - The maximum number of iterations done during calibration.numberOfThreads - The number of processor threads to be used.public int getMaxIterations()
public int getNumberOfThreads()
public void setReplicationParameters(boolean useAsOffset,
double lowerBound,
double upperBound,
int numberOfEvaluationPoints)
useAsOffset - Are the values of lower and upperBound to be understood as offsets from the par swap rate?lowerBound - The lowest strike allowed.upperBound - The maximal strike allowed.numberOfEvaluationPoints - The number of points to be evaluated during the integration.public boolean isReplicationUseAsOffset()
public double getReplicationLowerBound()
public double getReplicationUpperBound()
public int getReplicationNumberOfEvaluationPoints()
public LocalDate getReferenceDate()
public VolatilityCubeModel getModel()
public String getForwardCurveName()
public double[] getInitialParameters()
public void setInitialParameters(double[] initialParameters)
initialParameters - the initialParameters to setCopyright © 2019. All rights reserved.