Hi guys,
Just a few warnings about the CdsHelper class.
The standard market convention for CDS is that the default cover (and accrual) starts on the day after the valuation date - regardless of whether the start day is a holiday/weekend or not... currently the CdsHelper class counts only working days as valid.
Also, if a tenor is quoted, this invariably runs to the 20th of the next IMM month (roll convention of Following) or 20th of the month (Emerging Markets). So a 5Y CDS quoted now would finish on the 20th June 2013. Currently CdsHelper class would have it finishing on the 10th June 2013.
In addition, if you strip the curve using the MidPointCdsEngine (which is specified in the CdsHelper class) but price a CDS using the IntegralCdsEngine you don't recover the par-rates.
Regards,
Simon
------------------------------------------------------------------------- Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php _______________________________________________ QuantLib-dev mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/quantlib-dev |
On Fri, 2008-06-06 at 14:12 +0100, Simon Ibbotson wrote:
> Just a few warnings about the CdsHelper class. > > The standard market convention for CDS is that the default cover (and > accrual) starts on the day after the valuation date - regardless of > whether the start day is a holiday/weekend or not... currently the > CdsHelper class counts only working days as valid. I wasn't aware of this--thanks for the info. > Also, if a tenor is quoted, this invariably runs to the 20th of the > next IMM month (roll convention of Following) or 20th of the month > (Emerging Markets). So a 5Y CDS quoted now would finish on the 20th > June 2013. Currently CdsHelper class would have it finishing on the > 10th June 2013. This goes together with the IMM schedule I mentioned in a recent post. I'll try and fix it before release. > In addition, if you strip the curve using the MidPointCdsEngine (which > is specified in the CdsHelper class) but price a CDS using the > IntegralCdsEngine you don't recover the par-rates. True. I'll have to add a warning to this effect to the docs. Thanks, Luigi -- Humphrey's Requirements Uncertainty Principle: For a new software system, the requirements will not be completely known until after the users have used it. ------------------------------------------------------------------------- Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php _______________________________________________ QuantLib-dev mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/quantlib-dev |
Alternatively, if you set the period to be sufficiently long for the IntegralCdsEngine, you should recover the MidpointCdsEngine. So, you could deprecate the MidpointCdsEngine and set the default integration period to be suitably long in the IntegralCdsEngine.
Simon
On 6/6/08, Luigi Ballabio <[hidden email]> wrote:
On Fri, 2008-06-06 at 14:12 +0100, Simon Ibbotson wrote: ------------------------------------------------------------------------- Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php _______________________________________________ QuantLib-dev mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/quantlib-dev |
In reply to this post by Simon Ibbotson
On Fri, 2008-06-06 at 14:12 +0100, Simon Ibbotson wrote:
> Just a few warnings about the CdsHelper class. > > [...] > > If a tenor is quoted, this invariably runs to the 20th of the next IMM > month (roll convention of Following) or 20th of the month (Emerging > Markets). So a 5Y CDS quoted now would finish on the 20th June 2013. > Currently CdsHelper class would have it finishing on the 10th June > 2013. Simon, about running to the 20th: does it hold only for the maturity date, or for all coupon dates? Luigi -- Of course, if people could just act consistently, they could keep their desks clean, avoid cavities, lose weight, give up smoking, play a musical instrument, and possibly even produce software on a regular and timely basis. -- Alistair Cockburn ------------------------------------------------------------------------- Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php _______________________________________________ QuantLib-dev mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/quantlib-dev |
The 20th is the reference date for the maturity and all the coupon payments. It also serves as the roll date, meaning that the 5Y CDS is always >= 5years long. The payment dates and accrual are adjusted using the following convention.
Remember that a CDS maturing on one day includes accrual for both the first day of the period and the last day - and default coverage is in place for both days.
All the best,
Simon
On Thu, Jun 26, 2008 at 1:12 PM, Luigi Ballabio <[hidden email]> wrote:
------------------------------------------------------------------------- Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php _______________________________________________ QuantLib-dev mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/quantlib-dev |
In reply to this post by Simon Ibbotson
Simon,
as for this one: On Fri, 2008-06-06 at 14:12 +0100, Simon Ibbotson wrote: > The standard market convention for CDS is that the default cover (and > accrual) starts on the day after the valuation date - regardless of > whether the start day is a holiday/weekend or not... currently the > CdsHelper class counts only working days as valid. I'm not sure I follow. May you write a patch for this? Luigi -- Zawinski's Law: Every program attempts to expand until it can read mail. Those programs which cannot so expand are replaced by ones which can. ------------------------------------------------------------------------- Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php _______________________________________________ QuantLib-dev mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/quantlib-dev |
Okay - I'll write a patch to cover these issues.
On 6/27/08, Luigi Ballabio <[hidden email]> wrote: > Simon, > as for this one: > > On Fri, 2008-06-06 at 14:12 +0100, Simon Ibbotson wrote: >> The standard market convention for CDS is that the default cover (and >> accrual) starts on the day after the valuation date - regardless of >> whether the start day is a holiday/weekend or not... currently the >> CdsHelper class counts only working days as valid. > > I'm not sure I follow. May you write a patch for this? > > Luigi > > > -- > > Zawinski's Law: > Every program attempts to expand until it can read mail. Those > programs which cannot so expand are replaced by ones which can. > > > -- Sent from Gmail for mobile | mobile.google.com ------------------------------------------------------------------------- Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php _______________________________________________ QuantLib-dev mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/quantlib-dev |
On Sun, 2008-06-29 at 16:25 +0100, Simon Ibbotson wrote:
> Okay - I'll write a patch to cover these issues. Thanks--"these issues" being the start and end of the cover. As for the 20th convention, I've fixed that in the repository; you can now build the schedule with the relevant convention (or pass the convention to the CDS helper.) You might want to check my implementation to see that it works correctly. Luigi > On 6/27/08, Luigi Ballabio <[hidden email]> wrote: > > Simon, > > as for this one: > > > > On Fri, 2008-06-06 at 14:12 +0100, Simon Ibbotson wrote: > >> The standard market convention for CDS is that the default cover (and > >> accrual) starts on the day after the valuation date - regardless of > >> whether the start day is a holiday/weekend or not... currently the > >> CdsHelper class counts only working days as valid. > > > > I'm not sure I follow. May you write a patch for this? > > > > Luigi > > > > > > -- > > > > Zawinski's Law: > > Every program attempts to expand until it can read mail. Those > > programs which cannot so expand are replaced by ones which can. > > > > > > > -- A little inaccuracy sometimes saves tons of explanation. -- H.H. Munro, "Saki" ------------------------------------------------------------------------- Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php _______________________________________________ QuantLib-dev mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/quantlib-dev |
Oh, I see. Well, the only issue is that most coupon-bearing instruments use the convention "first, not last" in that they accrue the first day of a period but not the last day.
CDS have the convention "first and last", meaning that they accrue the last day of the CDS (not each period) as well as the first day. However, they also have default cover for the last day and the first day.
Therefore, although the official "maturity date" for the 5Y CDS may be 20th September 2013, for the purposes of calculation (accrual and probabilities) it is one day longer. Most quant libraries (which normally don't include the time of day for calculations) simply extend the last CDS period by one day - to 21st September 2013 in this case.
On 6/30/08, Luigi Ballabio <[hidden email]> wrote:
On Sun, 2008-06-29 at 16:25 +0100, Simon Ibbotson wrote: ------------------------------------------------------------------------- Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php _______________________________________________ QuantLib-dev mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/quantlib-dev |
I would make sure that the actual date in
the schedule is On a related point, protection on a CDS
traded on a Friday is unadjusted, and so starts on a Saturday. Is this how
things currently work in Quantlib? Thanks, Neil -----Original
Message----- Oh, I see. Well, the only
issue is that most coupon-bearing instruments use the convention "first,
not last" in that they accrue the first day of a period but not the last
day. CDS have the convention
"first and last", meaning that they accrue the last day of the CDS
(not each period) as well as the first day. However, they also have default
cover for the last day and the first day. Therefore, although the
official "maturity date" for the 5Y CDS may be 20th September 2013,
for the purposes of calculation (accrual and probabilities) it is one day
longer. Most quant libraries (which normally don't include the time of day for
calculations) simply extend the last CDS period by one day - to 21st September
2013 in this case.
On 6/30/08, Luigi Ballabio <[hidden email]> wrote:
On Sun, 2008-06-29 at 16:25 +0100, Simon Ibbotson
wrote: ------------------------------------------------------------------------- Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW! Studies have shown that voting for your favorite open source project, along with a healthy diet, reduces your potential for chronic lameness and boredom. Vote Now at http://www.sourceforge.net/community/cca08 _______________________________________________ QuantLib-dev mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/quantlib-dev |
Free forum by Nabble | Edit this page |