I am becoming more acquainted with QuantLib as a platform. I've been using both the python implementation and QuantLib XL. As I have started to look at CDS, I would like to know if there is a definitive guide to pricing CDS to match the outputs from Bloomberg? I have come across several old threads, but I can't seem to find a definitive successful example. If anyone can point me in the right direction, ideally in Python it would be appreciated.



The isda-engine.py example in the QuantLib-SWIG distribution reproduces Markit prices within fractions of cents.


You can download the C++ source code to the ISDA Standard CDS model (which JPM contributed) http://www.cdsmodel.com/cdsmodel/cds-disclaimer.html here. Its output will match Bloomberg if you use the same market data (including interest rates), dates, and other inputs.

  • $\begingroup$ thanks for this. if i am not mistaken this is not a quantlib solution however. $\endgroup$ – dsugasa Mar 21 '19 at 23:16
  • $\begingroup$ This is not quantlib, but another collection of C++ source code, showing how to calculate (risk neutral) survival probabilities or upfront fees from market standard quote spreads, how to pv a swap, etc to match Bloomberg CDSW exactly. If you're really asking how to do these calculations using just quantlib, please rephrase your question, because it's not so clear. $\endgroup$ – Dimitri Vulis Mar 22 '19 at 1:50
  • $\begingroup$ Thanks for your thoughts; this is very helpful $\endgroup$ – dsugasa Mar 22 '19 at 18:09

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.