Hi, I want to value a CPI Bond using a real, not nominal, yield curve. As I understand it, the current CPI Bond methodology requires some CPI indices, a zero inflation curve and a nominal yield curve. I don't have all those available, but I should be able to input a real curve instead of nominal curve (used in discounting) and a flat zero inflation curve consisting of rates = 0. It should give the same value. Conceptually, this method is also the same as valuing a fixed rate bond, but with an added inflation ratio adjustment, based on the CPI indices. But I'm struggling to create a zero inflation curve which is basically flat and all 0s. I've tried using PiecewiseZeroInflationCurve and with some instruments yielding 0s, but I end up with a curve that is not exactly flat or zero. I suspect it's a consequence of the historic CPI indices and the fact that they're interpolated. Are there any other ways, besides PiecewiseZeroInflationCurve to construct a ZeroInflationCurve? thanks Francois Botha
------------------------------------------------------------------------------ Learn Graph Databases - Download FREE O'Reilly Book "Graph Databases" is the definitive new guide to graph databases and their applications. Written by three acclaimed leaders in the field, this first edition is now available. Download your free book today! http://p.sf.net/sfu/NeoTech _______________________________________________ QuantLib-users mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/quantlib-users |
I think you should be able to manage with InterpolatedZeroInflationCurve.
Luigi On Tue, Jun 3, 2014 at 3:04 PM, Francois Botha <[hidden email]> wrote: > Hi, > > I want to value a CPI Bond using a real, not nominal, yield curve. As I > understand it, the current CPI Bond methodology requires some CPI indices, a > zero inflation curve and a nominal yield curve. I don't have all those > available, but I should be able to input a real curve instead of nominal > curve (used in discounting) and a flat zero inflation curve consisting of > rates = 0. > > It should give the same value. Conceptually, this method is also the same as > valuing a fixed rate bond, but with an added inflation ratio adjustment, > based on the CPI indices. > > But I'm struggling to create a zero inflation curve which is basically flat > and all 0s. I've tried using PiecewiseZeroInflationCurve and with some > instruments yielding 0s, but I end up with a curve that is not exactly flat > or zero. I suspect it's a consequence of the historic CPI indices and the > fact that they're interpolated. > > Are there any other ways, besides PiecewiseZeroInflationCurve to construct a > ZeroInflationCurve? > > thanks > Francois Botha > > ------------------------------------------------------------------------------ > Learn Graph Databases - Download FREE O'Reilly Book > "Graph Databases" is the definitive new guide to graph databases and their > applications. Written by three acclaimed leaders in the field, > this first edition is now available. Download your free book today! > http://p.sf.net/sfu/NeoTech > _______________________________________________ > QuantLib-users mailing list > [hidden email] > https://lists.sourceforge.net/lists/listinfo/quantlib-users > -- <https://implementingquantlib.blogspot.com> <https://twitter.com/lballabio> ------------------------------------------------------------------------------ Learn Graph Databases - Download FREE O'Reilly Book "Graph Databases" is the definitive new guide to graph databases and their applications. Written by three acclaimed leaders in the field, this first edition is now available. Download your free book today! http://p.sf.net/sfu/NeoTech _______________________________________________ QuantLib-users mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/quantlib-users |
Hi Francois,
if I get you right, your idea is to directly work in the real currency (which indeed may work for zero inflation coupons and nominal, I think ...). But why do you need to refer to CPI instruments at all then and not just work with usual fix rate bonds and a yield term structure for the real curve ? best Peter On 3 June 2014 15:37, Luigi Ballabio <[hidden email]> wrote: > I think you should be able to manage with InterpolatedZeroInflationCurve. > > Luigi > > On Tue, Jun 3, 2014 at 3:04 PM, Francois Botha <[hidden email]> wrote: >> Hi, >> >> I want to value a CPI Bond using a real, not nominal, yield curve. As I >> understand it, the current CPI Bond methodology requires some CPI indices, a >> zero inflation curve and a nominal yield curve. I don't have all those >> available, but I should be able to input a real curve instead of nominal >> curve (used in discounting) and a flat zero inflation curve consisting of >> rates = 0. >> >> It should give the same value. Conceptually, this method is also the same as >> valuing a fixed rate bond, but with an added inflation ratio adjustment, >> based on the CPI indices. >> >> But I'm struggling to create a zero inflation curve which is basically flat >> and all 0s. I've tried using PiecewiseZeroInflationCurve and with some >> instruments yielding 0s, but I end up with a curve that is not exactly flat >> or zero. I suspect it's a consequence of the historic CPI indices and the >> fact that they're interpolated. >> >> Are there any other ways, besides PiecewiseZeroInflationCurve to construct a >> ZeroInflationCurve? >> >> thanks >> Francois Botha >> >> ------------------------------------------------------------------------------ >> Learn Graph Databases - Download FREE O'Reilly Book >> "Graph Databases" is the definitive new guide to graph databases and their >> applications. Written by three acclaimed leaders in the field, >> this first edition is now available. Download your free book today! >> http://p.sf.net/sfu/NeoTech >> _______________________________________________ >> QuantLib-users mailing list >> [hidden email] >> https://lists.sourceforge.net/lists/listinfo/quantlib-users >> > > > > -- > <https://implementingquantlib.blogspot.com> > <https://twitter.com/lballabio> > > ------------------------------------------------------------------------------ > Learn Graph Databases - Download FREE O'Reilly Book > "Graph Databases" is the definitive new guide to graph databases and their > applications. Written by three acclaimed leaders in the field, > this first edition is now available. Download your free book today! > http://p.sf.net/sfu/NeoTech > _______________________________________________ > QuantLib-users mailing list > [hidden email] > https://lists.sourceforge.net/lists/listinfo/quantlib-users ------------------------------------------------------------------------------ Learn Graph Databases - Download FREE O'Reilly Book "Graph Databases" is the definitive new guide to graph databases and their applications. Written by three acclaimed leaders in the field, this first edition is now available. Download your free book today! http://p.sf.net/sfu/NeoTech _______________________________________________ QuantLib-users mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/quantlib-users |
I think he wants to use a "spot inflation index" (kind a dummy currency) and evaluates using real interest rates. It is a procedure usual in Brazilian inflation market, for example.
This procedure doesn't requires a inflation forecast curve, as long as the real rates are observable. Just as an example, all NTNB (Brazilian inflation bond) rates at the following like a real YTM: http://www3.tesouro.gov.br/tesouro_direto/consulta_titulos_novosite/consultatitulos.asp Regards, _____________________ Piter Dias > Date: Tue, 3 Jun 2014 20:02:12 +0200 > From: [hidden email] > To: [hidden email] > CC: [hidden email] > Subject: Re: [Quantlib-users] Valuing CPI Bond at real yield curve > > Hi Francois, > if I get you right, your idea is to directly work in the real > currency (which indeed may work for zero inflation coupons and > nominal, I think ...). But why do you need to refer to CPI instruments > at all then and not just work with usual fix rate bonds and a yield > term structure for the real curve ? > best > Peter > > On 3 June 2014 15:37, Luigi Ballabio <[hidden email]> wrote: > > I think you should be able to manage with InterpolatedZeroInflationCurve. > > > > Luigi > > > > On Tue, Jun 3, 2014 at 3:04 PM, Francois Botha <[hidden email]> wrote: > >> Hi, > >> > >> I want to value a CPI Bond using a real, not nominal, yield curve. As I > >> understand it, the current CPI Bond methodology requires some CPI indices, a > >> zero inflation curve and a nominal yield curve. I don't have all those > >> available, but I should be able to input a real curve instead of nominal > >> curve (used in discounting) and a flat zero inflation curve consisting of > >> rates = 0. > >> > >> It should give the same value. Conceptually, this method is also the same as > >> valuing a fixed rate bond, but with an added inflation ratio adjustment, > >> based on the CPI indices. > >> > >> But I'm struggling to create a zero inflation curve which is basically flat > >> and all 0s. I've tried using PiecewiseZeroInflationCurve and with some > >> instruments yielding 0s, but I end up with a curve that is not exactly flat > >> or zero. I suspect it's a consequence of the historic CPI indices and the > >> fact that they're interpolated. > >> > >> Are there any other ways, besides PiecewiseZeroInflationCurve to construct a > >> ZeroInflationCurve? > >> > >> thanks > >> Francois Botha > >> > >> ------------------------------------------------------------------------------ > >> Learn Graph Databases - Download FREE O'Reilly Book > >> "Graph Databases" is the definitive new guide to graph databases and their > >> applications. Written by three acclaimed leaders in the field, > >> this first edition is now available. Download your free book today! > >> http://p.sf.net/sfu/NeoTech > >> _______________________________________________ > >> QuantLib-users mailing list > >> [hidden email] > >> https://lists.sourceforge.net/lists/listinfo/quantlib-users > >> > > > > > > > > -- > > <https://implementingquantlib.blogspot.com> > > <https://twitter.com/lballabio> > > > > ------------------------------------------------------------------------------ > > Learn Graph Databases - Download FREE O'Reilly Book > > "Graph Databases" is the definitive new guide to graph databases and their > > applications. Written by three acclaimed leaders in the field, > > this first edition is now available. Download your free book today! > > http://p.sf.net/sfu/NeoTech > > _______________________________________________ > > QuantLib-users mailing list > > [hidden email] > > https://lists.sourceforge.net/lists/listinfo/quantlib-users > > ------------------------------------------------------------------------------ > Learn Graph Databases - Download FREE O'Reilly Book > "Graph Databases" is the definitive new guide to graph databases and their > applications. Written by three acclaimed leaders in the field, > this first edition is now available. Download your free book today! > http://p.sf.net/sfu/NeoTech > _______________________________________________ > QuantLib-users mailing list > [hidden email] > https://lists.sourceforge.net/lists/listinfo/quantlib-users ------------------------------------------------------------------------------ Learn Graph Databases - Download FREE O'Reilly Book "Graph Databases" is the definitive new guide to graph databases and their applications. Written by three acclaimed leaders in the field, this first edition is now available. Download your free book today! http://p.sf.net/sfu/NeoTech _______________________________________________ QuantLib-users mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/quantlib-users |
Thanks. Yes, Piter explains it correctly. Peter, the standard fixed rate bond pricing calculation is almost correct, but an inflation factor has to be applied. I think of it as an 'accumulated inflation' factor that represents the growth in coupons from issue date to valuation date. See page 4 and 5 of http://www.riskworx.co.za/resources/Inflation-linked%20Instruments.pdf for the full methodology.
regards Francois Botha
On 3 June 2014 20:10, Piter Dias <[hidden email]> wrote:
------------------------------------------------------------------------------ Learn Graph Databases - Download FREE O'Reilly Book "Graph Databases" is the definitive new guide to graph databases and their applications. Written by three acclaimed leaders in the field, this first edition is now available. Download your free book today! http://p.sf.net/sfu/NeoTech _______________________________________________ QuantLib-users mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/quantlib-users |
yes, understand. So you use the CPI classes only to compute this fixed
adjustment factor ? I would have thought that this can easily computed out of the historic fixings (using the index, but without attached curve necessary) and then used to adjust the rate and nominal in a usual fixed rate bond. anyway, main thing is that is works. interesting case, thanks Peter On 3 June 2014 23:46, Francois Botha <[hidden email]> wrote: > Thanks. > > Yes, Piter explains it correctly. > > Peter, the standard fixed rate bond pricing calculation is almost correct, > but an inflation factor has to be applied. I think of it as an 'accumulated > inflation' factor that represents the growth in coupons from issue date to > valuation date. See page 4 and 5 of > http://www.riskworx.co.za/resources/Inflation-linked%20Instruments.pdf for > the full methodology. > > regards > > Francois Botha > > > On 3 June 2014 20:10, Piter Dias <[hidden email]> wrote: >> >> I think he wants to use a "spot inflation index" (kind a dummy currency) >> and evaluates using real interest rates. It is a procedure usual in >> Brazilian inflation market, for example. >> >> This procedure doesn't requires a inflation forecast curve, as long as the >> real rates are observable. >> >> Just as an example, all NTNB (Brazilian inflation bond) rates at the >> following like a real YTM: >> http://www3.tesouro.gov.br/tesouro_direto/consulta_titulos_novosite/consultatitulos.asp >> >> Regards, >> >> >> _____________________ >> Piter Dias >> [hidden email] >> www.piterdias.com >> >> >> >> > Date: Tue, 3 Jun 2014 20:02:12 +0200 >> > From: [hidden email] >> > To: [hidden email] >> > CC: [hidden email] >> > Subject: Re: [Quantlib-users] Valuing CPI Bond at real yield curve >> >> > >> > Hi Francois, >> > if I get you right, your idea is to directly work in the real >> > currency (which indeed may work for zero inflation coupons and >> > nominal, I think ...). But why do you need to refer to CPI instruments >> > at all then and not just work with usual fix rate bonds and a yield >> > term structure for the real curve ? >> > best >> > Peter >> > >> > On 3 June 2014 15:37, Luigi Ballabio <[hidden email]> wrote: >> > > I think you should be able to manage with >> > > InterpolatedZeroInflationCurve. >> > > >> > > Luigi >> > > >> > > On Tue, Jun 3, 2014 at 3:04 PM, Francois Botha <[hidden email]> >> > > wrote: >> > >> Hi, >> > >> >> > >> I want to value a CPI Bond using a real, not nominal, yield curve. As >> > >> I >> > >> understand it, the current CPI Bond methodology requires some CPI >> > >> indices, a >> > >> zero inflation curve and a nominal yield curve. I don't have all >> > >> those >> > >> available, but I should be able to input a real curve instead of >> > >> nominal >> > >> curve (used in discounting) and a flat zero inflation curve >> > >> consisting of >> > >> rates = 0. >> > >> >> > >> It should give the same value. Conceptually, this method is also the >> > >> same as >> > >> valuing a fixed rate bond, but with an added inflation ratio >> > >> adjustment, >> > >> based on the CPI indices. >> > >> >> > >> But I'm struggling to create a zero inflation curve which is >> > >> basically flat >> > >> and all 0s. I've tried using PiecewiseZeroInflationCurve and with >> > >> some >> > >> instruments yielding 0s, but I end up with a curve that is not >> > >> exactly flat >> > >> or zero. I suspect it's a consequence of the historic CPI indices and >> > >> the >> > >> fact that they're interpolated. >> > >> >> > >> Are there any other ways, besides PiecewiseZeroInflationCurve to >> > >> construct a >> > >> ZeroInflationCurve? >> > >> >> > >> thanks >> > >> Francois Botha >> > >> >> > >> >> > >> ------------------------------------------------------------------------------ >> > >> Learn Graph Databases - Download FREE O'Reilly Book >> > >> "Graph Databases" is the definitive new guide to graph databases and >> > >> their >> > >> applications. Written by three acclaimed leaders in the field, >> > >> this first edition is now available. Download your free book today! >> > >> http://p.sf.net/sfu/NeoTech >> > >> _______________________________________________ >> > >> QuantLib-users mailing list >> > >> [hidden email] >> > >> https://lists.sourceforge.net/lists/listinfo/quantlib-users >> > >> >> > > >> > > >> > > >> > > -- >> > > <https://implementingquantlib.blogspot.com> >> > > <https://twitter.com/lballabio> >> > > >> > > >> > > ------------------------------------------------------------------------------ >> > > Learn Graph Databases - Download FREE O'Reilly Book >> > > "Graph Databases" is the definitive new guide to graph databases and >> > > their >> > > applications. Written by three acclaimed leaders in the field, >> > > this first edition is now available. Download your free book today! >> > > http://p.sf.net/sfu/NeoTech >> > > _______________________________________________ >> > > QuantLib-users mailing list >> > > [hidden email] >> > > https://lists.sourceforge.net/lists/listinfo/quantlib-users >> > >> > >> > ------------------------------------------------------------------------------ >> > Learn Graph Databases - Download FREE O'Reilly Book >> > "Graph Databases" is the definitive new guide to graph databases and >> > their >> > applications. Written by three acclaimed leaders in the field, >> > this first edition is now available. Download your free book today! >> > http://p.sf.net/sfu/NeoTech >> > _______________________________________________ >> > QuantLib-users mailing list >> > [hidden email] >> > https://lists.sourceforge.net/lists/listinfo/quantlib-users >> >> >> ------------------------------------------------------------------------------ >> Learn Graph Databases - Download FREE O'Reilly Book >> "Graph Databases" is the definitive new guide to graph databases and their >> applications. Written by three acclaimed leaders in the field, >> this first edition is now available. Download your free book today! >> http://p.sf.net/sfu/NeoTech >> _______________________________________________ >> QuantLib-users mailing list >> [hidden email] >> https://lists.sourceforge.net/lists/listinfo/quantlib-users >> > ------------------------------------------------------------------------------ Learn Graph Databases - Download FREE O'Reilly Book "Graph Databases" is the definitive new guide to graph databases and their applications. Written by three acclaimed leaders in the field, this first edition is now available. Download your free book today! http://p.sf.net/sfu/NeoTech _______________________________________________ QuantLib-users mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/quantlib-users |
I specifically didn't want to make any ad hoc, manual adjustments, because after I manage to calculate a CPI bond's value correctly, I want to implement a CPIBondHelper and then bootstrap the *real* yield curve using that, similar to FixedRateBondHelper and bootstrapping a nominal yield curve. Introducing any manual adjustments will make the bootstrapping difficult.
But thanks, Luigi, using InterpolatedZeroYieldCurve I managed to do what I wanted. I'm still not 100% replicating the CPI bond's value, but I'll fine tune the input parameters in the next few days. I'm starting to work on a CPIBondHelper now. Thanks for the other input too. regards Francois Botha
On 4 June 2014 13:41, Peter Caspers <[hidden email]> wrote: yes, understand. So you use the CPI classes only to compute this fixed ------------------------------------------------------------------------------ Learn Graph Databases - Download FREE O'Reilly Book "Graph Databases" is the definitive new guide to graph databases and their applications. Written by three acclaimed leaders in the field, this first edition is now available. Download your free book today! http://p.sf.net/sfu/NeoTech _______________________________________________ QuantLib-users mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/quantlib-users |
Hi Francois
I would like to do this using quantlib-swig through python. Do you think this is possible at this stage? There are no CPI bond examples that I am aware of at present for swig in python. I attempted to get the scala version working,see here, but I have had no luck and in any event this does not look like an example with a known real curve. Any idea how I can take this forward? Thanks Charles |
Hi Charles. Unfortunately I know very little about the SWIG bindings, but I'm sure one of the other people can help. On 19 Dec 2015 13:07, "Charles Allderman" <[hidden email]> wrote:
Hi Francois ------------------------------------------------------------------------------ _______________________________________________ QuantLib-users mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/quantlib-users |
Thanks Francois can you perhaps post, send me your C++ code for a CPI bond against reference CPI, for the multiplication factor, and discounted off the real curve? On 19 Dec 2015 1:35 p.m., "Francois Botha" <[hidden email]> wrote:
------------------------------------------------------------------------------ _______________________________________________ QuantLib-users mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/quantlib-users |
Hi Francois
I got official version working thanks to John Orford on this forum. The issue it seems was that the inflationIndex object needed one date instead of multiple index points. My assumption was it would pull out the latest valid point. The way the pricer works is that the real coupons are increased by the inflation rate curve term structure, zciisData. The result therefore becomes a nominal future cash flow. To price then the bondpricer simply discounts these by the nominal term structure. I added some additional code to print the determined cash flows and the "growth factor" and then the discount rate. Doing it this way I think is fine for my purposes at present. Thanks Charles |
Can you replicate the BESA market prices exactly or don't you need that accuracy? I needed accuracy to the 5th decimal in order to bootstrap a yield curve that matches our own internal curve. But I found some discrepancies in the inflation index interpolation that threw out the bond valuation, just slightly, but enough to distort my yield curve enough. On 24 Dec 2015 10:49, "Charles Allderman" <[hidden email]> wrote:
Hi Francois ------------------------------------------------------------------------------ _______________________________________________ QuantLib-users mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/quantlib-users |
I don't need that sort of accuracy. Looking forward to using you real curve modifications though. On Thu, Dec 24, 2015 at 11:12 AM, Francois Botha <[hidden email]> wrote:
------------------------------------------------------------------------------ _______________________________________________ QuantLib-users mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/quantlib-users |
Free forum by Nabble | Edit this page |