public class CmsTradeCalculations extends Object
This provides a high-level entry point for CMS pricing and risk measures.
CMS pricing uses swaption volatilities with the SABR model.
Additional model parameters must be specified using CmsSabrExtrapolationParams.
Each method takes a ResolvedCmsTrade, whereas application code will
typically work with CmsTrade. Call
CmsTrade::resolve(ReferenceData)
to convert CmsTrade to ResolvedCmsTrade.
| Constructor and Description |
|---|
CmsTradeCalculations(SabrExtrapolationReplicationCmsTradePricer tradePricer)
Creates an instance specifying the SABR pricer.
|
| Modifier and Type | Method and Description |
|---|---|
MultiCurrencyScenarioArray |
currencyExposure(ResolvedCmsTrade trade,
RatesMarketDataLookup ratesLookup,
SwaptionMarketDataLookup swaptionLookup,
ScenarioMarketData marketData)
Calculates currency exposure across one or more scenarios.
|
MultiCurrencyAmount |
currencyExposure(ResolvedCmsTrade trade,
RatesProvider ratesProvider,
SwaptionVolatilities volatilities)
Calculates currency exposure for a single set of market data.
|
MultiCurrencyScenarioArray |
currentCash(ResolvedCmsTrade trade,
RatesMarketDataLookup ratesLookup,
SwaptionMarketDataLookup swaptionLookup,
ScenarioMarketData marketData)
Calculates current cash across one or more scenarios.
|
MultiCurrencyAmount |
currentCash(ResolvedCmsTrade trade,
RatesProvider ratesProvider,
SwaptionVolatilities volatilities)
Calculates current cash for a single set of market data.
|
static CmsTradeCalculations |
of(CmsSabrExtrapolationParams cmsParams)
Obtains an instance specifying the SABR extrapolation parameters.
|
MultiCurrencyScenarioArray |
presentValue(ResolvedCmsTrade trade,
RatesMarketDataLookup ratesLookup,
SwaptionMarketDataLookup swaptionLookup,
ScenarioMarketData marketData)
Calculates present value across one or more scenarios.
|
MultiCurrencyAmount |
presentValue(ResolvedCmsTrade trade,
RatesProvider ratesProvider,
SwaptionVolatilities volatilities)
Calculates present value for a single set of market data.
|
ScenarioArray<CurrencyParameterSensitivities> |
pv01RatesCalibratedBucketed(ResolvedCmsTrade trade,
RatesMarketDataLookup ratesLookup,
SwaptionMarketDataLookup swaptionLookup,
ScenarioMarketData marketData)
Calculates present value sensitivity across one or more scenarios.
|
CurrencyParameterSensitivities |
pv01RatesCalibratedBucketed(ResolvedCmsTrade trade,
RatesProvider ratesProvider,
SwaptionVolatilities volatilities)
Calculates present value sensitivity for a single set of market data.
|
MultiCurrencyScenarioArray |
pv01RatesCalibratedSum(ResolvedCmsTrade trade,
RatesMarketDataLookup ratesLookup,
SwaptionMarketDataLookup swaptionLookup,
ScenarioMarketData marketData)
Calculates present value sensitivity across one or more scenarios.
|
MultiCurrencyAmount |
pv01RatesCalibratedSum(ResolvedCmsTrade trade,
RatesProvider ratesProvider,
SwaptionVolatilities volatilities)
Calculates present value sensitivity for a single set of market data.
|
ScenarioArray<CurrencyParameterSensitivities> |
pv01RatesMarketQuoteBucketed(ResolvedCmsTrade trade,
RatesMarketDataLookup ratesLookup,
SwaptionMarketDataLookup swaptionLookup,
ScenarioMarketData marketData)
Calculates present value sensitivity across one or more scenarios.
|
CurrencyParameterSensitivities |
pv01RatesMarketQuoteBucketed(ResolvedCmsTrade trade,
RatesProvider ratesProvider,
SwaptionVolatilities volatilities)
Calculates present value sensitivity for a single set of market data.
|
MultiCurrencyScenarioArray |
pv01RatesMarketQuoteSum(ResolvedCmsTrade trade,
RatesMarketDataLookup ratesLookup,
SwaptionMarketDataLookup swaptionLookup,
ScenarioMarketData marketData)
Calculates present value sensitivity across one or more scenarios.
|
MultiCurrencyAmount |
pv01RatesMarketQuoteSum(ResolvedCmsTrade trade,
RatesProvider ratesProvider,
SwaptionVolatilities volatilities)
Calculates present value sensitivity for a single set of market data.
|
public CmsTradeCalculations(SabrExtrapolationReplicationCmsTradePricer tradePricer)
tradePricer - the pricer for ResolvedCmsTradepublic static CmsTradeCalculations of(CmsSabrExtrapolationParams cmsParams)
cmsParams - the parameters for SABR pricing of CMSpublic MultiCurrencyScenarioArray presentValue(ResolvedCmsTrade trade, RatesMarketDataLookup ratesLookup, SwaptionMarketDataLookup swaptionLookup, ScenarioMarketData marketData)
trade - the traderatesLookup - the lookup used to query the market dataswaptionLookup - the lookup used to query the swaption market datamarketData - the market datapublic MultiCurrencyAmount presentValue(ResolvedCmsTrade trade, RatesProvider ratesProvider, SwaptionVolatilities volatilities)
trade - the traderatesProvider - the market datavolatilities - the swaption volatilitiespublic MultiCurrencyScenarioArray pv01RatesCalibratedSum(ResolvedCmsTrade trade, RatesMarketDataLookup ratesLookup, SwaptionMarketDataLookup swaptionLookup, ScenarioMarketData marketData)
This is the sensitivity of present value to a one basis point shift in the calibrated curves. The result is the sum of the sensitivities of all affected curves.
trade - the traderatesLookup - the lookup used to query the market dataswaptionLookup - the lookup used to query the swaption market datamarketData - the market datapublic MultiCurrencyAmount pv01RatesCalibratedSum(ResolvedCmsTrade trade, RatesProvider ratesProvider, SwaptionVolatilities volatilities)
This is the sensitivity of present value to a one basis point shift in the calibrated curves. The result is the sum of the sensitivities of all affected curves.
trade - the traderatesProvider - the market datavolatilities - the swaption volatilitiespublic ScenarioArray<CurrencyParameterSensitivities> pv01RatesCalibratedBucketed(ResolvedCmsTrade trade, RatesMarketDataLookup ratesLookup, SwaptionMarketDataLookup swaptionLookup, ScenarioMarketData marketData)
This is the sensitivity of present value to a one basis point shift in the calibrated curves. The result is provided for each affected curve and currency, bucketed by curve node.
trade - the traderatesLookup - the lookup used to query the market dataswaptionLookup - the lookup used to query the swaption market datamarketData - the market datapublic CurrencyParameterSensitivities pv01RatesCalibratedBucketed(ResolvedCmsTrade trade, RatesProvider ratesProvider, SwaptionVolatilities volatilities)
This is the sensitivity of present value to a one basis point shift in the calibrated curves. The result is provided for each affected curve and currency, bucketed by curve node.
trade - the traderatesProvider - the market datavolatilities - the swaption volatilitiespublic MultiCurrencyScenarioArray pv01RatesMarketQuoteSum(ResolvedCmsTrade trade, RatesMarketDataLookup ratesLookup, SwaptionMarketDataLookup swaptionLookup, ScenarioMarketData marketData)
This is the sensitivity of present value to a one basis point shift in the market quotes used to calibrate the curves. The result is the sum of the sensitivities of all affected curves.
trade - the traderatesLookup - the lookup used to query the market dataswaptionLookup - the lookup used to query the swaption market datamarketData - the market datapublic MultiCurrencyAmount pv01RatesMarketQuoteSum(ResolvedCmsTrade trade, RatesProvider ratesProvider, SwaptionVolatilities volatilities)
This is the sensitivity of present value to a one basis point shift in the market quotes used to calibrate the curves. The result is the sum of the sensitivities of all affected curves.
trade - the traderatesProvider - the market datavolatilities - the swaption volatilitiespublic ScenarioArray<CurrencyParameterSensitivities> pv01RatesMarketQuoteBucketed(ResolvedCmsTrade trade, RatesMarketDataLookup ratesLookup, SwaptionMarketDataLookup swaptionLookup, ScenarioMarketData marketData)
This is the sensitivity of present value to a one basis point shift in the market quotes used to calibrate the curves. The result is provided for each affected curve and currency, bucketed by curve node.
trade - the traderatesLookup - the lookup used to query the market datamarketData - the market dataswaptionLookup - the lookup used to query the swaption market datapublic CurrencyParameterSensitivities pv01RatesMarketQuoteBucketed(ResolvedCmsTrade trade, RatesProvider ratesProvider, SwaptionVolatilities volatilities)
This is the sensitivity of present value to a one basis point shift in the market quotes used to calibrate the curves. The result is provided for each affected curve and currency, bucketed by curve node.
trade - the traderatesProvider - the market datavolatilities - the swaption volatilitiespublic MultiCurrencyScenarioArray currencyExposure(ResolvedCmsTrade trade, RatesMarketDataLookup ratesLookup, SwaptionMarketDataLookup swaptionLookup, ScenarioMarketData marketData)
The currency risk, expressed as the equivalent amount in each currency.
trade - the traderatesLookup - the lookup used to query the market dataswaptionLookup - the lookup used to query the swaption market datamarketData - the market datapublic MultiCurrencyAmount currencyExposure(ResolvedCmsTrade trade, RatesProvider ratesProvider, SwaptionVolatilities volatilities)
The currency risk, expressed as the equivalent amount in each currency.
trade - the traderatesProvider - the market datavolatilities - the swaption volatilitiespublic MultiCurrencyScenarioArray currentCash(ResolvedCmsTrade trade, RatesMarketDataLookup ratesLookup, SwaptionMarketDataLookup swaptionLookup, ScenarioMarketData marketData)
The sum of all cash flows paid on the valuation date.
trade - the traderatesLookup - the lookup used to query the market dataswaptionLookup - the lookup used to query the swaption market datamarketData - the market datapublic MultiCurrencyAmount currentCash(ResolvedCmsTrade trade, RatesProvider ratesProvider, SwaptionVolatilities volatilities)
The sum of all cash flows paid on the valuation date.
trade - the traderatesProvider - the market datavolatilities - the swaption volatilitiesCopyright 2009-Present by OpenGamma Inc. and individual contributors
Apache v2 licensed
Additional documentation can be found at strata.opengamma.io.