QuantLib: a free/open-source library for quantitative finance
Reference manual - version 1.40
Loading...
Searching...
No Matches
XabrSwaptionVolatilityCube< Model > Class Template Reference

XABR Swaption Volatility Cube. More...

#include <ql/termstructures/volatility/swaption/sabrswaptionvolatilitycube.hpp>

Inheritance diagram for XabrSwaptionVolatilityCube< Model >:

Public Member Functions

 XabrSwaptionVolatilityCube (const Handle< SwaptionVolatilityStructure > &atmVolStructure, const std::vector< Period > &optionTenors, const std::vector< Period > &swapTenors, const std::vector< Spread > &strikeSpreads, const std::vector< std::vector< Handle< Quote > > > &volSpreads, const ext::shared_ptr< SwapIndex > &swapIndexBase, const ext::shared_ptr< SwapIndex > &shortSwapIndexBase, bool vegaWeightedSmileFit, std::vector< std::vector< Handle< Quote > > > parametersGuess, std::vector< bool > isParameterFixed, bool isAtmCalibrated, ext::shared_ptr< EndCriteria > endCriteria=ext::shared_ptr< EndCriteria >(), Real maxErrorTolerance=Null< Real >(), ext::shared_ptr< OptimizationMethod > optMethod=ext::shared_ptr< OptimizationMethod >(), Real errorAccept=Null< Real >(), bool useMaxError=false, Size maxGuesses=50, bool backwardFlat=false, Real cutoffStrike=0.0001)
LazyObject interface
void performCalculations () const override
SwaptionVolatilityCube interface
ext::shared_ptr< SmileSectionsmileSectionImpl (Time optionTime, Time swapLength) const override
Public Member Functions inherited from SwaptionVolatilityCube
 SwaptionVolatilityCube (const Handle< SwaptionVolatilityStructure > &atmVolStructure, const std::vector< Period > &optionTenors, const std::vector< Period > &swapTenors, const std::vector< Spread > &strikeSpreads, std::vector< std::vector< Handle< Quote > > > volSpreads, ext::shared_ptr< SwapIndex > swapIndexBase, ext::shared_ptr< SwapIndex > shortSwapIndexBase, bool vegaWeightedSmileFit)
DayCounter dayCounter () const override
 the day counter used for date/time conversion
Date maxDate () const override
 the latest date for which the curve can return values
Time maxTime () const override
 the latest time for which the curve can return values
const DatereferenceDate () const override
 the date at which discount = 1.0 and/or variance = 0.0
Calendar calendar () const override
 the calendar used for reference and/or option date calculation
Natural settlementDays () const override
 the settlementDays used for reference date calculation
Rate minStrike () const override
 the minimum strike for which the term structure can return vols
Rate maxStrike () const override
 the maximum strike for which the term structure can return vols
const PeriodmaxSwapTenor () const override
 the largest length for which the term structure can return vols
Rate atmStrike (const Date &optionDate, const Period &swapTenor) const
Rate atmStrike (const Period &optionTenor, const Period &swapTenor) const
Handle< SwaptionVolatilityStructureatmVol () const
const std::vector< Spread > & strikeSpreads () const
const std::vector< std::vector< Handle< Quote > > > & volSpreads () const
ext::shared_ptr< SwapIndexswapIndexBase () const
ext::shared_ptr< SwapIndexshortSwapIndexBase () const
bool vegaWeightedSmileFit () const
VolatilityType volatilityType () const override
 volatility type

Other inspectors

const MatrixmarketVolCube (Size i) const
Matrix sparseSabrParameters () const
Matrix denseSabrParameters () const
Matrix marketVolCube () const
Matrix volCubeAtmCalibrated () const
void sabrCalibrationSection (const Cube &marketVolCube, Cube &parametersCube, const Period &swapTenor) const
void recalibration (Real beta, const Period &swapTenor)
void recalibration (const std::vector< Real > &beta, const Period &swapTenor)
void recalibration (const std::vector< Period > &swapLengths, const std::vector< Real > &beta, const Period &swapTenor)
void updateAfterRecalibration ()
void registerWithParametersGuess ()
void setParameterGuess () const
ext::shared_ptr< SmileSectionsmileSection (Time optionTime, Time swapLength, const Cube &sabrParametersCube) const
Cube sabrCalibration (const Cube &marketVolCube) const
void fillVolatilityCube () const
void createSparseSmiles () const
std::vector< RealspreadVolInterpolation (const Date &atmOptionDate, const Period &atmSwapTenor) const

Additional Inherited Members

void registerWithVolatilitySpread ()
Volatility volatilityImpl (Time optionTime, Time swapLength, Rate strike) const override
Volatility volatilityImpl (const Date &optionDate, const Period &swapTenor, Rate strike) const override
Real shiftImpl (Time optionTime, Time swapLength) const override
Handle< SwaptionVolatilityStructureatmVol_
Size nStrikes_
std::vector< SpreadstrikeSpreads_
std::vector< RatelocalStrikes_
std::vector< VolatilitylocalSmile_
std::vector< std::vector< Handle< Quote > > > volSpreads_
ext::shared_ptr< SwapIndexswapIndexBase_
ext::shared_ptr< SwapIndexshortSwapIndexBase_
bool vegaWeightedSmileFit_

Detailed Description

template<class Model>
class QuantLib::XabrSwaptionVolatilityCube< Model >

XABR Swaption Volatility Cube.

This class implements the XABR Swaption Volatility Cube which is a generic for different SABR, ZABR and different smile models that can be used to instantiate concrete cubes.

Member Function Documentation

◆ performCalculations()

template<class Model>
void performCalculations ( ) const
overridevirtual

This method must implement any calculations which must be (re)done in order to calculate the desired results.

Reimplemented from SwaptionVolatilityCube.

◆ smileSectionImpl()

template<class Model>
ext::shared_ptr< SmileSection > smileSectionImpl ( Time optionTime,
Time swapLength ) const
overridevirtual