quantlib.termstructures.credit.interpolated_hazardrate_curve.
InterpolatedHazardRateCurve¶
- class InterpolatedHazardRateCurve(Interpolator interpolator, list dates, vector[Rate] hazard_rates, DayCounter day_counter, Calendar cal=Calendar())¶
Bases:
DefaultProbabilityTermStructureDefaultProbabilityTermStructure based on interpolation of hazard rates
- Parameters:
- interpolatorint {Linear, LogLinear, BackwardFlat}
can be one of Linear, LogLinear, BackwardFlat
- dates
listofDate list of dates
- hazard_rates
listof float corresponding list of hazard rates
- day_counter
DayCounter - cal
Calendar
- Attributes:
calendarCalendar: calendardatalist of curve data
dateslist of curve dates
day_counterDayCounter: day counterhazard_rateslist of curve hazard rates
- jump_dates
- jump_times
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 calculationtimeslist of curve times
Methods
hazard_rate(self, d, bool extrapolate=False)Hazard rate
survival_probability(self, d, ...)Survival probability
time_from_reference(self, Date dt)date/time conversion