Skip to main content

Tools designed for use with CDS data

Project description

This package offers users simple tools designed for Credit Default Swap (CDS) data. Included in this package is a hazard rate bootstrapping function which implements the JP Morgan model for determining hazard rate curves, and spread calculators for both vanilla and binary CDSs. All functions linearly interpolate/extrapolate yield curve values wherever necessary.

To be included in future releases will be a function that prices Credit Default Swaptions (options on CDSs). Also, later editions of this package will offer the users options for interpolating/extrapolating yield curve values.

Bootstrapping Function: This function implements the so-called JP Morgan model. This model makes the assumptions that the interest rate process is independent of the default process and that default leg pays at the end of each accrual period. Typically, regular fee payments occur at the end of each period. To that end, this model assumes that defaults occur midway buring each payment period. And finally, this model assumes that the hazard rate is piecewise constant on the intervals that correspond to the maturities of the CDS contracts.

CDS pricing function: This function calculates the “fair” spread of a vanilla CDS, i.e. the spread that makes the value of the default/floating leg equal to the value of the payment/fixed leg. This is accomplished by using a given yield curve and given credit curve.

Binary CDS pricing function: Similar to the previous function, this one calculates the “fair” spread of a binary CDS by finding the spread that equates the value of the default/floating leg equal to the value of the payment/fixed leg. This is also accomplished using a provided yield curve and credit curve

Change Log

0.0.1 (10/08/2020)

  • First Release

0.0.2 (10/10/2020)

  • CDS spread calculator added. Some typos corrected.

0.0.3 (10/11/2020)

  • Yield curve interpolation/extrapolation component was corrected.

  • Binary CDS spread calculator added.

  • Documentation updated

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

cdstools-0.0.3.tar.gz (5.0 kB view hashes)

Uploaded Source

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page