finpricing.market#

Submodules#

Package Contents#

Classes#

SurvivalCurveNelsonSiegel

SurvivalCurveStep

CDSCurve

RecoveryCurve

class finpricing.market.SurvivalCurveNelsonSiegel(anchor_date: finpricing.utils.date.Date | datetime.date, pivot_dates: list[finpricing.utils.date.Date | datetime.date], params: list[float] = None)[source]#

Bases: SurvivalCurve

static f(t, a)[source]#
static f_integral(t, a)[source]#
hazard_rates(t: float) float[source]#
survival(date: finpricing.utils.date.Date | datetime.date)[source]#
getSurvivalCurve(params: list[float])[source]#

create a new survival curve with the same anchor date and pivot dates but different parameters

class finpricing.market.SurvivalCurveStep(anchor_date: finpricing.utils.Date | finpricing.utils.datetime.date, dates: List[finpricing.utils.Date | finpricing.utils.datetime.date], hazard_rates: List[float], day_count_type=DayCountTypes.ACT_ACT_ISDA)[source]#
survival(date: finpricing.utils.datetime.date | finpricing.utils.Date) float[source]#
class finpricing.market.CDSCurve(market_date: datetime.date | finpricing.utils.Date, expiries: List[datetime.date | finpricing.utils.Date], spreads: List[float], upfronts: List[float], cds_style: finpricing.utils.CDSStyle | str)[source]#
class finpricing.market.RecoveryCurve[source]#