public final class NormalOvernightFutureOptionExpirySimpleMoneynessVolatilities extends Object implements NormalOvernightFutureOptionVolatilities, org.joda.beans.ImmutableBean, Serializable
The volatility is represented by a surface on the expiry and simple moneyness. The expiry is measured in number of days (not time) according to a day-count convention. The simple moneyness can be on the price or on the rate (1-price).
| Modifier and Type | Class and Description |
|---|---|
static class |
NormalOvernightFutureOptionExpirySimpleMoneynessVolatilities.Builder
The bean-builder for
NormalOvernightFutureOptionExpirySimpleMoneynessVolatilities. |
static class |
NormalOvernightFutureOptionExpirySimpleMoneynessVolatilities.Meta
The meta-bean for
NormalOvernightFutureOptionExpirySimpleMoneynessVolatilities. |
| Modifier and Type | Method and Description |
|---|---|
static NormalOvernightFutureOptionExpirySimpleMoneynessVolatilities.Builder |
builder()
Returns a builder used to create an instance of the bean.
|
boolean |
equals(Object obj) |
<T> Optional<T> |
findData(MarketDataName<T> name) |
OptionalInt |
findParameterIndex(ParameterMetadata metadata) |
OvernightIndex |
getIndex()
Gets the index of the underlying future.
|
OvernightFutureOptionVolatilitiesName |
getName()
Gets the name of these volatilities.
|
double |
getParameter(int parameterIndex) |
int |
getParameterCount() |
ParameterMetadata |
getParameterMetadata(int parameterIndex) |
Surface |
getSurface()
Gets the normal volatility surface.
|
ZonedDateTime |
getValuationDateTime()
Gets the valuation date-time.
|
int |
hashCode() |
static NormalOvernightFutureOptionExpirySimpleMoneynessVolatilities.Meta |
meta()
The meta-bean for
NormalOvernightFutureOptionExpirySimpleMoneynessVolatilities. |
NormalOvernightFutureOptionExpirySimpleMoneynessVolatilities.Meta |
metaBean() |
static NormalOvernightFutureOptionExpirySimpleMoneynessVolatilities |
of(OvernightIndex index,
ZonedDateTime valuationDateTime,
Surface surface)
Obtains an instance from the volatility surface and the date-time for which it is valid.
|
CurrencyParameterSensitivities |
parameterSensitivity(PointSensitivities pointSensitivities)
Calculates the parameter sensitivity.
|
double |
relativeTime(ZonedDateTime zonedDateTime)
Converts a time and date to a relative year fraction.
|
NormalOvernightFutureOptionExpirySimpleMoneynessVolatilities.Builder |
toBuilder()
Returns a builder that allows this bean to be mutated.
|
String |
toString() |
double |
volatility(double expiry,
LocalDate fixingDate,
double strikePrice,
double futurePrice)
Calculates the volatility at the specified expiry.
|
NormalOvernightFutureOptionExpirySimpleMoneynessVolatilities |
withParameter(int parameterIndex,
double newValue) |
NormalOvernightFutureOptionExpirySimpleMoneynessVolatilities |
withPerturbation(ParameterPerturbation perturbation) |
clone, finalize, getClass, notify, notifyAll, wait, wait, waitgetVolatilityTypegetValuationDate, parameterSensitivity, volatilitypublic static NormalOvernightFutureOptionExpirySimpleMoneynessVolatilities of(OvernightIndex index, ZonedDateTime valuationDateTime, Surface surface)
The surface is specified by an instance of Surface, such as InterpolatedNodalSurface.
The surface must contain the correct metadata:
ValueType.YEAR_FRACTION
ValueType.SIMPLE_MONEYNESS
ValueType.NORMAL_VOLATILITY
SurfaceInfoType.DAY_COUNT
Surfaces.normalVolatilityByExpirySimpleMoneyness(String, DayCount, MoneynessType).index - the Overnight indexsurface - the implied volatility surfacevaluationDateTime - the valuation date-timepublic OvernightFutureOptionVolatilitiesName getName()
OvernightFutureOptionVolatilitiesgetName in interface OvernightFutureOptionVolatilitiespublic <T> Optional<T> findData(MarketDataName<T> name)
findData in interface MarketDataViewpublic int getParameterCount()
getParameterCount in interface ParameterizedDatapublic double getParameter(int parameterIndex)
getParameter in interface ParameterizedDatapublic ParameterMetadata getParameterMetadata(int parameterIndex)
getParameterMetadata in interface ParameterizedDatapublic OptionalInt findParameterIndex(ParameterMetadata metadata)
findParameterIndex in interface ParameterizedDatapublic NormalOvernightFutureOptionExpirySimpleMoneynessVolatilities withParameter(int parameterIndex, double newValue)
withParameter in interface ParameterizedDatawithParameter in interface NormalOvernightFutureOptionVolatilitieswithParameter in interface OvernightFutureOptionVolatilitiespublic NormalOvernightFutureOptionExpirySimpleMoneynessVolatilities withPerturbation(ParameterPerturbation perturbation)
withPerturbation in interface ParameterizedDatawithPerturbation in interface NormalOvernightFutureOptionVolatilitieswithPerturbation in interface OvernightFutureOptionVolatilitiespublic double volatility(double expiry,
LocalDate fixingDate,
double strikePrice,
double futurePrice)
OvernightFutureOptionVolatilities
This relies on expiry supplied by OvernightFutureOptionVolatilities.relativeTime(ZonedDateTime).
volatility in interface OvernightFutureOptionVolatilitiesexpiry - the time to expiry as a year fractionfixingDate - the underlying future fixing datestrikePrice - the option strike pricefuturePrice - the price of the underlying futurepublic CurrencyParameterSensitivities parameterSensitivity(PointSensitivities pointSensitivities)
OvernightFutureOptionVolatilities
This computes the CurrencyParameterSensitivities associated with the PointSensitivities.
This corresponds to the projection of the point sensitivity to the internal parameters representation.
parameterSensitivity in interface OvernightFutureOptionVolatilitiespointSensitivities - the point sensitivitiespublic double relativeTime(ZonedDateTime zonedDateTime)
OvernightFutureOptionVolatilitiesWhen the date is after the valuation date (and potentially time), the returned number is negative.
relativeTime in interface OvernightFutureOptionVolatilitieszonedDateTime - the date-time to find the relative year fraction ofpublic static NormalOvernightFutureOptionExpirySimpleMoneynessVolatilities.Meta meta()
NormalOvernightFutureOptionExpirySimpleMoneynessVolatilities.public static NormalOvernightFutureOptionExpirySimpleMoneynessVolatilities.Builder builder()
public NormalOvernightFutureOptionExpirySimpleMoneynessVolatilities.Meta metaBean()
metaBean in interface org.joda.beans.Beanpublic OvernightIndex getIndex()
getIndex in interface OvernightFutureOptionVolatilitiespublic ZonedDateTime getValuationDateTime()
The volatilities are calibrated for this date-time.
getValuationDateTime in interface OvernightFutureOptionVolatilitiespublic Surface getSurface()
The x-value of the surface is the expiry, as a year fraction. The y-value of the surface is the simple moneyness.
public NormalOvernightFutureOptionExpirySimpleMoneynessVolatilities.Builder toBuilder()
Copyright 2009-Present by OpenGamma Inc. and individual contributors
Apache v2 licensed
Additional documentation can be found at strata.opengamma.io.