BlackConstantVol¶
- class BlackConstantVol(Date reference_date, Calendar calendar, volatility, DayCounter daycounter, settlement_days=None)¶
Bases:
BlackVolatilityTermStructureConstant Black volatility, no time-strike dependence
This class implements the BlackVolatilityTermStructure interface for a constant Black volatility (no time/strike dependence)
- Parameters:
- reference_date
Date - calendar
Calendar - volatilityfloat or
Quote - day_counter: :obj:`DayCounter`
- settlement_days: Natural
- reference_date
- Attributes:
calendarCalendar: calendarday_counterDayCounter: day counter- extrapolation
max_dateDate: the latest date for which the curve can return valuesmax_timeTime: the latest time for which the curve can return valuesreference_dateDate: the date at which discount = 1.0 and/or variance = 0.0settlement_daysint: number of settlement days used for reference date calculation
Methods
blackForwardVariance(self, time_1, time_2, ...)forward (at-the-money) variance
blackForwardVol(self, time_1, time_2, ...)forward (at-the-money) volatility
blackVariance(self, maturity, Real strike, ...)spot variance
blackVol(self, maturity, Real strike, ...)spot volatility
option_date_from_tenor(self, Period period)time_from_reference(self, Date dt)date/time conversion