public class SabrSwaptionTradePricer extends Object
The swap underlying the swaption must have a fixed leg on which the forward rate is computed. The underlying swap must be single currency.
The volatility parameters are not adjusted for the underlying swap convention. The volatilities from the provider are taken as such.
The present value and sensitivities of the premium, if in the future, are also taken into account.
| Modifier and Type | Field and Description |
|---|---|
static SabrSwaptionTradePricer |
DEFAULT
Default implementation.
|
| Constructor and Description |
|---|
SabrSwaptionTradePricer(SabrSwaptionCashParYieldProductPricer cashParYieldPricer,
SabrSwaptionPhysicalProductPricer physicalPricer,
DiscountingPaymentPricer paymentPricer)
Creates an instance.
|
| Modifier and Type | Method and Description |
|---|---|
MultiCurrencyAmount |
currencyExposure(ResolvedSwaptionTrade trade,
RatesProvider ratesProvider,
SabrSwaptionVolatilities swaptionVolatilities)
Computes the currency exposure of the swaption trade.
|
CurrencyAmount |
currentCash(ResolvedSwaptionTrade trade,
LocalDate valuationDate)
Calculates the current cash of the swaption trade.
|
double |
forwardRate(ResolvedSwaptionTrade swaptionTrade,
RatesProvider ratesProvider)
Provides the forward rate.
|
double |
impliedVolatility(ResolvedSwaptionTrade swaptionTrade,
RatesProvider ratesProvider,
SwaptionVolatilities swaptionVolatilities)
Computes the implied volatility of the swaption.
|
CurrencyAmount |
presentValue(ResolvedSwaptionTrade trade,
RatesProvider ratesProvider,
SabrSwaptionVolatilities swaptionVolatilities)
Calculates the present value of the swaption trade.
|
PointSensitivities |
presentValueSensitivityModelParamsSabr(ResolvedSwaptionTrade trade,
RatesProvider ratesProvider,
SabrSwaptionVolatilities swaptionVolatilities)
Calculates the present value sensitivity to the SABR model parameters of the swaption trade.
|
PointSensitivities |
presentValueSensitivityModelParamsVolatility(ResolvedSwaptionTrade trade,
RatesProvider ratesProvider,
SabrSwaptionVolatilities swaptionVolatilities)
Calculates the present value sensitivity to the implied volatility of the swaption trade.
|
PointSensitivities |
presentValueSensitivityRatesStickyModel(ResolvedSwaptionTrade trade,
RatesProvider ratesProvider,
SabrSwaptionVolatilities swaptionVolatilities)
Calculates the present value sensitivity of the swaption trade to the rate curves.
|
PointSensitivities |
presentValueSensitivityRatesStickyStrike(ResolvedSwaptionTrade trade,
RatesProvider ratesProvider,
SabrSwaptionVolatilities swaptionVolatilities)
Calculates the present value sensitivity of the swaption trade to the rate curves.
|
public static final SabrSwaptionTradePricer DEFAULT
public SabrSwaptionTradePricer(SabrSwaptionCashParYieldProductPricer cashParYieldPricer, SabrSwaptionPhysicalProductPricer physicalPricer, DiscountingPaymentPricer paymentPricer)
cashParYieldPricer - the pricer for cash par yieldphysicalPricer - the pricer for physicalpaymentPricer - the pricer for Paymentpublic CurrencyAmount presentValue(ResolvedSwaptionTrade trade, RatesProvider ratesProvider, SabrSwaptionVolatilities swaptionVolatilities)
The result is expressed using the currency of the swaption.
trade - the swaption traderatesProvider - the rates providerswaptionVolatilities - the volatilitiespublic PointSensitivities presentValueSensitivityRatesStickyStrike(ResolvedSwaptionTrade trade, RatesProvider ratesProvider, SabrSwaptionVolatilities swaptionVolatilities)
The present value sensitivity is computed in a "sticky strike" style, i.e. the sensitivity to the curve nodes with the volatility at the swaption strike unchanged. This sensitivity does not include a potential change of volatility due to the implicit change of forward rate or moneyness.
trade - the swaption traderatesProvider - the rates providerswaptionVolatilities - the volatilitiespublic PointSensitivities presentValueSensitivityRatesStickyModel(ResolvedSwaptionTrade trade, RatesProvider ratesProvider, SabrSwaptionVolatilities swaptionVolatilities)
The present value sensitivity is computed in a "sticky model parameter" style, i.e. the sensitivity to the curve nodes with the SABR model parameters unchanged. This sensitivity does not include a potential re-calibration of the model parameters to the raw market data.
trade - the swaption traderatesProvider - the rates providerswaptionVolatilities - the volatilitiespublic PointSensitivities presentValueSensitivityModelParamsVolatility(ResolvedSwaptionTrade trade, RatesProvider ratesProvider, SabrSwaptionVolatilities swaptionVolatilities)
trade - the swaption traderatesProvider - the rates providerswaptionVolatilities - the volatilitiespublic PointSensitivities presentValueSensitivityModelParamsSabr(ResolvedSwaptionTrade trade, RatesProvider ratesProvider, SabrSwaptionVolatilities swaptionVolatilities)
The sensitivity of the present value to the SABR model parameters, alpha, beta, rho and nu.
trade - the swaption traderatesProvider - the rates providerswaptionVolatilities - the volatilitiespublic MultiCurrencyAmount currencyExposure(ResolvedSwaptionTrade trade, RatesProvider ratesProvider, SabrSwaptionVolatilities swaptionVolatilities)
trade - the swaption traderatesProvider - the rates providerswaptionVolatilities - the volatilitiespublic double impliedVolatility(ResolvedSwaptionTrade swaptionTrade, RatesProvider ratesProvider, SwaptionVolatilities swaptionVolatilities)
swaptionTrade - the swaption traderatesProvider - the rates providerswaptionVolatilities - the volatilitiespublic double forwardRate(ResolvedSwaptionTrade swaptionTrade, RatesProvider ratesProvider)
This is the par rate for the forward starting swap that is the underlying of the swaption.
swaptionTrade - the swaption traderatesProvider - the rates providerpublic CurrencyAmount currentCash(ResolvedSwaptionTrade trade, LocalDate valuationDate)
Only the premium is contributing to the current cash for non-cash settle swaptions.
trade - the swaption tradevaluationDate - the valuation dateCopyright 2009-Present by OpenGamma Inc. and individual contributors
Apache v2 licensed
Additional documentation can be found at strata.opengamma.io.