public final class NormalIborFutureOptionMarginedTradePricer extends Object
This provides the ability to price an Ibor future option. The option must be based on daily margin.
Strata uses decimal prices for Ibor future options in the trade model, pricers and market data. The decimal price is based on the decimal rate equivalent to the percentage. For example, an option price of 0.2 is related to a futures price of 99.32 that implies an interest rate of 0.68%. Strata represents the price of the future as 0.9932 and thus represents the price of the option as 0.002.
| Modifier and Type | Field and Description |
|---|---|
static NormalIborFutureOptionMarginedTradePricer |
DEFAULT
Default implementation.
|
| Constructor and Description |
|---|
NormalIborFutureOptionMarginedTradePricer(NormalIborFutureOptionMarginedProductPricer futureOptionPricer)
Creates an instance.
|
| Modifier and Type | Method and Description |
|---|---|
CurrencyAmount |
presentValue(ResolvedIborFutureOptionTrade trade,
LocalDate valuationDate,
double currentOptionPrice,
double lastOptionSettlementPrice)
Calculates the present value of the Ibor future option trade from the current option price.
|
CurrencyAmount |
presentValue(ResolvedIborFutureOptionTrade trade,
RatesProvider ratesProvider,
NormalIborFutureOptionVolatilities volatilities,
double lastOptionSettlementPrice)
Calculates the present value of the Ibor future option trade.
|
CurrencyAmount |
presentValue(ResolvedIborFutureOptionTrade trade,
RatesProvider ratesProvider,
NormalIborFutureOptionVolatilities volatilities,
double futurePrice,
double lastOptionSettlementPrice)
Calculates the present value of the Ibor future option trade from the underlying future price.
|
IborFutureOptionSensitivity |
presentValueSensitivityModelParamsVolatility(ResolvedIborFutureOptionTrade futureOptionTrade,
RatesProvider ratesProvider,
NormalIborFutureOptionVolatilities volatilities)
Computes the present value sensitivity to the normal volatility used in the pricing.
|
IborFutureOptionSensitivity |
presentValueSensitivityModelParamsVolatility(ResolvedIborFutureOptionTrade futureOptionTrade,
RatesProvider ratesProvider,
NormalIborFutureOptionVolatilities volatilities,
double futurePrice)
Computes the present value sensitivity to the normal volatility used in the pricing
based on the price of the underlying future.
|
PointSensitivities |
presentValueSensitivityRates(ResolvedIborFutureOptionTrade trade,
RatesProvider ratesProvider,
NormalIborFutureOptionVolatilities volatilities)
Calculates the present value sensitivity of the Ibor future option trade.
|
double |
price(ResolvedIborFutureOptionTrade trade,
RatesProvider ratesProvider,
NormalIborFutureOptionVolatilities volatilities)
Calculates the price of the Ibor future option trade.
|
public static final NormalIborFutureOptionMarginedTradePricer DEFAULT
public NormalIborFutureOptionMarginedTradePricer(NormalIborFutureOptionMarginedProductPricer futureOptionPricer)
futureOptionPricer - the pricer for IborFutureOptionpublic double price(ResolvedIborFutureOptionTrade trade, RatesProvider ratesProvider, NormalIborFutureOptionVolatilities volatilities)
The price of the trade is the price on the valuation date. The price is calculated using the volatility model.
trade - the traderatesProvider - the rates providervolatilities - the volatilitiespublic CurrencyAmount presentValue(ResolvedIborFutureOptionTrade trade, LocalDate valuationDate, double currentOptionPrice, double lastOptionSettlementPrice)
The present value of the product is the value on the valuation date. The current price is specified, not calculated.
This method calculates based on the difference between the specified current price and the last settlement price, or the trade price if traded on the valuation date.
trade - the tradevaluationDate - the valuation date; required to asses if the trade or last closing price should be usedcurrentOptionPrice - the current price for the option, in decimal formlastOptionSettlementPrice - the last settlement price used for margining for the option, in decimal formpublic CurrencyAmount presentValue(ResolvedIborFutureOptionTrade trade, RatesProvider ratesProvider, NormalIborFutureOptionVolatilities volatilities, double lastOptionSettlementPrice)
The present value of the product is the value on the valuation date. The current price is calculated using the volatility model.
This method calculates based on the difference between the model price and the last settlement price, or the trade price if traded on the valuation date.
trade - the traderatesProvider - the rates providervolatilities - the volatilitieslastOptionSettlementPrice - the last settlement price used for margining for the option, in decimal formpublic CurrencyAmount presentValue(ResolvedIborFutureOptionTrade trade, RatesProvider ratesProvider, NormalIborFutureOptionVolatilities volatilities, double futurePrice, double lastOptionSettlementPrice)
The present value of the product is the value on the valuation date. The current price is calculated using the volatility model with a known future price.
This method calculates based on the difference between the model price and the last settlement price, or the trade price if traded on the valuation date.
trade - the traderatesProvider - the rates providervolatilities - the volatilitiesfuturePrice - the price of the underlying future, in decimal formlastOptionSettlementPrice - the last settlement price used for margining for the option, in decimal formpublic PointSensitivities presentValueSensitivityRates(ResolvedIborFutureOptionTrade trade, RatesProvider ratesProvider, NormalIborFutureOptionVolatilities volatilities)
The present value sensitivity of the trade is the sensitivity of the present value to the underlying curves.
trade - the traderatesProvider - the rates providervolatilities - the volatilitiespublic IborFutureOptionSensitivity presentValueSensitivityModelParamsVolatility(ResolvedIborFutureOptionTrade futureOptionTrade, RatesProvider ratesProvider, NormalIborFutureOptionVolatilities volatilities)
The result is a single sensitivity to the volatility used. The volatility is associated with the expiry/delay/strike/future price key combination.
This calculates the underlying future price using the future pricer.
futureOptionTrade - the traderatesProvider - the rates providervolatilities - the volatilitiespublic IborFutureOptionSensitivity presentValueSensitivityModelParamsVolatility(ResolvedIborFutureOptionTrade futureOptionTrade, RatesProvider ratesProvider, NormalIborFutureOptionVolatilities volatilities, double futurePrice)
The result is a single sensitivity to the volatility used. The volatility is associated with the expiry/delay/strike/future price key combination.
futureOptionTrade - the traderatesProvider - the rates providervolatilities - the volatilitiesfuturePrice - the price of the underlying future, in decimal formCopyright 2009-Present by OpenGamma Inc. and individual contributors
Apache v2 licensed
Additional documentation can be found at strata.opengamma.io.