Go to Deriscope's documentation start page

CDS_Functions

Function Implied Hazard Rate within CDS returns the flat hazard rate that would cause the given Implied Hazard Rate to have the quoted price, as calculated by QuantLib's impliedHazardRate() function
The Implied Hazard Rate price calculation is based on the
Model[CDS]::Pricing Method::Mid Point Cds method.
Note this method performs the calculation with the instrument characteristics.
It will coincide with the ISDA calculation if your object has the standard characteristics. Notably:
- The calendar should have no bank holidays, just weekends.
- The yield curve should be LIBOR piecewise constant in fwd rates, with a discount factor of 1 on the calculation date, which coincides with the trade date.
- Convention should be Following for yield curve and contract cashflows.
- The CDS should pay accrued and mature on standard IMM dates, settle on trade date +1 and upfront settle on trade date +3.

Function Conventional Spread within CDS returns the conventional spread, as calculated by QuantLib's conventionalSpread() function
First the implied hazard rate for a target NPV = 0 is calculated using the
CDS::Implied Hazard Rate function.
Then a credit curve is constructed taking as input a flat hazard rate equal to the one found above.
Finally the fair spread (i.e. the running premium that makes the CDS have zero price) is calculated and returned.
The CDS price calculation is based on the
Model[CDS]::Pricing Method::Mid Point Cds method.
Note this method performs the calculation with the instrument characteristics.
It will coincide with the ISDA calculation if your object has the standard characteristics. Notably:
- The calendar should have no bank holidays, just weekends.
- The yield curve should be LIBOR piecewise constant in fwd rates, with a discount factor of 1 on the calculation date, which coincides with the trade date.
- Convention should be Following for yield curve and contract cashflows.
- The CDS should pay accrued and mature on standard IMM dates, settle on trade date +1 and upfront settle on trade date +3.