Calculates option's Vanna. More...
#include <optionVanna.hpp>
Public Member Functions | |
OptionVanna (SmartPointer< OptionGreeks > input, double hs, double hv, std::string risk_name="Vanna") | |
Constructor. More... | |
std::map< std::string, double > | getRisks (const SmartPointer< MarketModel > &model, const SmartPointer< PricingEngine > &prizer, const SmartPointer< Option > &option) |
returns the PV and Greek parameter More... | |
GreeksIntermediateResults | calculateRisks (const SmartPointer< MarketModel > &model, const SmartPointer< PricingEngine > &prizer, const SmartPointer< Option > &option) |
calculates the option's Vanna More... | |
OptionVanna * | clone () const |
Virtual copy constructor. More... | |
Public Member Functions inherited from julian::OptionGreeksDecorator | |
OptionGreeksDecorator (SmartPointer< OptionGreeks > risks) | |
Constructor. More... | |
Public Member Functions inherited from julian::OptionGreeks | |
virtual | ~OptionGreeks () |
Destructor. More... | |
Private Attributes | |
double | hs_ |
Increment used in differencing scheme for spot direction. More... | |
double | hv_ |
Increment used in differencing scheme for volatility direction. More... | |
std::string | risk_name_ |
Risk name that will be used as key for result map. Default name is Vanna. More... | |
Detailed Description
Calculates option's Vanna.
This method calculates Vanna. Using the method prize of julian::PricingEngine and bumpVolatility/bumpSpot of julian::MarketModel it calculates the cross-derivative of option prize wrt to spot and volatility.
Vanna of option is calculated using the finite difference scheme
The result is saved in map. OptionVanna is a concrete decorator in decorator structure. Concrete Decorator is a class that altered alters the behaviour of Concrete Component.
- Todo:
- Implement different schemes for numerical differentiation. At this moment only central differencing is implemented.
Constructor & Destructor Documentation
|
inline |
Constructor.
Member Function Documentation
|
virtual |
calculates the option's Vanna
Vanna of option is calculated using the finite difference scheme
- Returns
- method returns map with key "Vanna" and value of Vanna
Reimplemented from julian::OptionGreeksDecorator.
|
virtual |
Virtual copy constructor.
Reimplemented from julian::OptionGreeksDecorator.
|
virtual |
returns the PV and Greek parameter
- Returns
- method returns map with name of Greeks as key and the value of Greeks as value
Reimplemented from julian::OptionGreeksDecorator.
Member Data Documentation
|
private |
Increment used in differencing scheme for spot direction.
|
private |
Increment used in differencing scheme for volatility direction.
|
private |
Risk name that will be used as key for result map. Default name is Vanna.
The documentation for this class was generated from the following files:
- C:/Unix/home/OEM/jULIAN/src/pricingEngines/optionGreeks/optionVanna.hpp
- C:/Unix/home/OEM/jULIAN/src/pricingEngines/optionGreeks/optionVanna.cpp