Quantcast

Building a USD discount curve using public market data

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Building a USD discount curve using public market data

Marco Craveiro
Hi Quantlib-Users,

I am performing a simple exercise to help me understand Quantlib
better: to price Netflix options [1] using only publicly available
market data, as a "regular consumer/individual" would. My first step
is to build a yield curve, followed by a second step working on the
vol surface. I have a few questions which hopefully pertain to this
forum; these questions are as much about methodology as they are about
Quantlib, so apologies in advance if this is not the right place.

I have read a number of articles on bootstrapping and bumping discount
curves using Quantlib (e.g. [1], [2], [3]). The code is very clear.
However, all of these articles seem to be focused on a "commercial"
market - i.e. Interbank/Hedge funds and so forth - since they use
Depos, FRAs and Swaps on the discount curve. Presumably, individuals
do not have access to buy/sell these instruments and as such should
not add them to their discount curves? Or is the availability of the
instruments not relevant for this purpose? Personally, I was going to
use only the instruments available in the Treasury website [3], but
I'd be interested to hear other opinions and any pointers to
articles/mails etc on bootstrapping curves/vol surfaces using only
freely available market data.

Kind regards
--
Marco Craveiro

[1] https://www.google.com/finance/option_chain?q=NASDAQ:NFLX
[2] http://www.billiontrader.com/post/102
[3] http://gouthamanbalaraman.com/blog/quantlib-term-structure-bootstrap-yield-curve.html
[4] http://www.bnikolic.co.uk/blog/ql-bumping-curve.html
[5] https://www.treasury.gov/resource-center/data-chart-center/interest-rates/Pages/TextView.aspx?data=yield

MD, Domain Driven Consulting
about: http://about.me/marcocraveiro
blog: http://mcraveiro.blogspot.co.uk
twitter: https://twitter.com/MarcoCraveiro

That the Ideas are themselves manifestations (of the Idea-Idea) and
that the Idea-Idea is a-kind-of Manifestation-Idea—which is a-kind-of
itself, so that the system is completely self-describing— would have
been appreciated by Plato as an extremely practical joke [Plato]. --
Alan Key

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Building a USD discount curve using public market data

John O'Sullivan
Marco,

This spreadsheet pulls a load of depo, futures & swap rates from quandl to bootstrap a yield curve. I tested it with QuantLibXL 1.4 when I built it.


It likely won't work right off the bat for you as I suspect some of the quandl datasets have changed recently. But hopefully you can get some traction with quandl datasets and the general idea. I am planning to update and retest the sheet soon as part of a wider test effort, so if you follow on github you'll be notified.

Cheers
John

On 6 January 2017 at 11:34, Marco Craveiro <[hidden email]> wrote:
Hi Quantlib-Users,

I am performing a simple exercise to help me understand Quantlib
better: to price Netflix options [1] using only publicly available
market data, as a "regular consumer/individual" would. My first step
is to build a yield curve, followed by a second step working on the
vol surface. I have a few questions which hopefully pertain to this
forum; these questions are as much about methodology as they are about
Quantlib, so apologies in advance if this is not the right place.

I have read a number of articles on bootstrapping and bumping discount
curves using Quantlib (e.g. [1], [2], [3]). The code is very clear.
However, all of these articles seem to be focused on a "commercial"
market - i.e. Interbank/Hedge funds and so forth - since they use
Depos, FRAs and Swaps on the discount curve. Presumably, individuals
do not have access to buy/sell these instruments and as such should
not add them to their discount curves? Or is the availability of the
instruments not relevant for this purpose? Personally, I was going to
use only the instruments available in the Treasury website [3], but
I'd be interested to hear other opinions and any pointers to
articles/mails etc on bootstrapping curves/vol surfaces using only
freely available market data.

Kind regards
--
Marco Craveiro

[1] https://www.google.com/finance/option_chain?q=NASDAQ:NFLX
[2] http://www.billiontrader.com/post/102
[3] http://gouthamanbalaraman.com/blog/quantlib-term-structure-bootstrap-yield-curve.html
[4] http://www.bnikolic.co.uk/blog/ql-bumping-curve.html
[5] https://www.treasury.gov/resource-center/data-chart-center/interest-rates/Pages/TextView.aspx?data=yield

MD, Domain Driven Consulting
about: http://about.me/marcocraveiro
blog: http://mcraveiro.blogspot.co.uk
twitter: https://twitter.com/MarcoCraveiro

That the Ideas are themselves manifestations (of the Idea-Idea) and
that the Idea-Idea is a-kind-of Manifestation-Idea—which is a-kind-of
itself, so that the system is completely self-describing— would have
been appreciated by Plato as an extremely practical joke [Plato]. --
Alan Key

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Building a USD discount curve using public market data

Marco Craveiro
Hi John,

Thanks very much, that is extremely helpful - I will follow your
github project keenly.

While we're at it, do you have an opinion in terms of the methodology
side of my question? i.e. do you think it is sensible to add any
instruments which are only available in the interbank market/to hedge
funds when pricing options for the "ordinary" consumer? I'm wondering
if it does not give you an unrealistic view of risk.

Thanks

On 6 January 2017 at 17:43, John O'Sullivan <[hidden email]> wrote:

> Marco,
>
> This spreadsheet pulls a load of depo, futures & swap rates from quandl to
> bootstrap a yield curve. I tested it with QuantLibXL 1.4 when I built it.
>
> https://github.com/SpreadServe/ssxls/blob/master/ycb_quandl_pub.xls
>
> It likely won't work right off the bat for you as I suspect some of the
> quandl datasets have changed recently. But hopefully you can get some
> traction with quandl datasets and the general idea. I am planning to update
> and retest the sheet soon as part of a wider test effort, so if you follow
> on github you'll be notified.
>
> Cheers
> John
>
> On 6 January 2017 at 11:34, Marco Craveiro <[hidden email]> wrote:
>>
>> Hi Quantlib-Users,
>>
>> I am performing a simple exercise to help me understand Quantlib
>> better: to price Netflix options [1] using only publicly available
>> market data, as a "regular consumer/individual" would. My first step
>> is to build a yield curve, followed by a second step working on the
>> vol surface. I have a few questions which hopefully pertain to this
>> forum; these questions are as much about methodology as they are about
>> Quantlib, so apologies in advance if this is not the right place.
>>
>> I have read a number of articles on bootstrapping and bumping discount
>> curves using Quantlib (e.g. [1], [2], [3]). The code is very clear.
>> However, all of these articles seem to be focused on a "commercial"
>> market - i.e. Interbank/Hedge funds and so forth - since they use
>> Depos, FRAs and Swaps on the discount curve. Presumably, individuals
>> do not have access to buy/sell these instruments and as such should
>> not add them to their discount curves? Or is the availability of the
>> instruments not relevant for this purpose? Personally, I was going to
>> use only the instruments available in the Treasury website [3], but
>> I'd be interested to hear other opinions and any pointers to
>> articles/mails etc on bootstrapping curves/vol surfaces using only
>> freely available market data.
>>
>> Kind regards
>> --
>> Marco Craveiro
>>
>> [1] https://www.google.com/finance/option_chain?q=NASDAQ:NFLX
>> [2] http://www.billiontrader.com/post/102
>> [3]
>> http://gouthamanbalaraman.com/blog/quantlib-term-structure-bootstrap-yield-curve.html
>> [4] http://www.bnikolic.co.uk/blog/ql-bumping-curve.html
>> [5]
>> https://www.treasury.gov/resource-center/data-chart-center/interest-rates/Pages/TextView.aspx?data=yield
>>
>> MD, Domain Driven Consulting
>> about: http://about.me/marcocraveiro
>> blog: http://mcraveiro.blogspot.co.uk
>> twitter: https://twitter.com/MarcoCraveiro
>>
>> That the Ideas are themselves manifestations (of the Idea-Idea) and
>> that the Idea-Idea is a-kind-of Manifestation-Idea—which is a-kind-of
>> itself, so that the system is completely self-describing— would have
>> been appreciated by Plato as an extremely practical joke [Plato]. --
>> Alan Key
>>
>>
>> ------------------------------------------------------------------------------
>> Check out the vibrant tech community on one of the world's most
>> engaging tech sites, SlashDot.org! http://sdm.link/slashdot
>> _______________________________________________
>> QuantLib-users mailing list
>> [hidden email]
>> https://lists.sourceforge.net/lists/listinfo/quantlib-users
>
>



--
Marco Craveiro

MD, Domain Driven Consulting
about: http://about.me/marcocraveiro
blog: http://mcraveiro.blogspot.co.uk
twitter: https://twitter.com/MarcoCraveiro

That the Ideas are themselves manifestations (of the Idea-Idea) and
that the Idea-Idea is a-kind-of Manifestation-Idea—which is a-kind-of
itself, so that the system is completely self-describing— would have
been appreciated by Plato as an extremely practical joke [Plato]. --
Alan Key

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Building a USD discount curve using public market data

John O'Sullivan
Marco,

Two thoughts on the methodology question, bearing in mind I claim no expertise!

1. Rates pricing systems I've worked with at a tier one firm used the most liquid instrument at every point in the curve. For example, Eurex bund, bobl & schatz.
2. You may be pricing options for retail traders, but who they gonna trade with? Their broker counterparties will have better market data and pricing tools, but the retail traders will likely be best served by the closest approximation to the prices their brokers trade on. 

Cheers
John

On 6 January 2017 at 18:00, Marco Craveiro <[hidden email]> wrote:
Hi John,

Thanks very much, that is extremely helpful - I will follow your
github project keenly.

While we're at it, do you have an opinion in terms of the methodology
side of my question? i.e. do you think it is sensible to add any
instruments which are only available in the interbank market/to hedge
funds when pricing options for the "ordinary" consumer? I'm wondering
if it does not give you an unrealistic view of risk.

Thanks

On 6 January 2017 at 17:43, John O'Sullivan <[hidden email]> wrote:
> Marco,
>
> This spreadsheet pulls a load of depo, futures & swap rates from quandl to
> bootstrap a yield curve. I tested it with QuantLibXL 1.4 when I built it.
>
> https://github.com/SpreadServe/ssxls/blob/master/ycb_quandl_pub.xls
>
> It likely won't work right off the bat for you as I suspect some of the
> quandl datasets have changed recently. But hopefully you can get some
> traction with quandl datasets and the general idea. I am planning to update
> and retest the sheet soon as part of a wider test effort, so if you follow
> on github you'll be notified.
>
> Cheers
> John
>
> On 6 January 2017 at 11:34, Marco Craveiro <[hidden email]> wrote:
>>
>> Hi Quantlib-Users,
>>
>> I am performing a simple exercise to help me understand Quantlib
>> better: to price Netflix options [1] using only publicly available
>> market data, as a "regular consumer/individual" would. My first step
>> is to build a yield curve, followed by a second step working on the
>> vol surface. I have a few questions which hopefully pertain to this
>> forum; these questions are as much about methodology as they are about
>> Quantlib, so apologies in advance if this is not the right place.
>>
>> I have read a number of articles on bootstrapping and bumping discount
>> curves using Quantlib (e.g. [1], [2], [3]). The code is very clear.
>> However, all of these articles seem to be focused on a "commercial"
>> market - i.e. Interbank/Hedge funds and so forth - since they use
>> Depos, FRAs and Swaps on the discount curve. Presumably, individuals
>> do not have access to buy/sell these instruments and as such should
>> not add them to their discount curves? Or is the availability of the
>> instruments not relevant for this purpose? Personally, I was going to
>> use only the instruments available in the Treasury website [3], but
>> I'd be interested to hear other opinions and any pointers to
>> articles/mails etc on bootstrapping curves/vol surfaces using only
>> freely available market data.
>>
>> Kind regards
>> --
>> Marco Craveiro
>>
>> [1] https://www.google.com/finance/option_chain?q=NASDAQ:NFLX
>> [2] http://www.billiontrader.com/post/102
>> [3]
>> http://gouthamanbalaraman.com/blog/quantlib-term-structure-bootstrap-yield-curve.html
>> [4] http://www.bnikolic.co.uk/blog/ql-bumping-curve.html
>> [5]
>> https://www.treasury.gov/resource-center/data-chart-center/interest-rates/Pages/TextView.aspx?data=yield
>>
>> MD, Domain Driven Consulting
>> about: http://about.me/marcocraveiro
>> blog: http://mcraveiro.blogspot.co.uk
>> twitter: https://twitter.com/MarcoCraveiro
>>
>> That the Ideas are themselves manifestations (of the Idea-Idea) and
>> that the Idea-Idea is a-kind-of Manifestation-Idea—which is a-kind-of
>> itself, so that the system is completely self-describing— would have
>> been appreciated by Plato as an extremely practical joke [Plato]. --
>> Alan Key
>>
>>
>> ------------------------------------------------------------------------------
>> Check out the vibrant tech community on one of the world's most
>> engaging tech sites, SlashDot.org! http://sdm.link/slashdot
>> _______________________________________________
>> QuantLib-users mailing list
>> [hidden email]
>> https://lists.sourceforge.net/lists/listinfo/quantlib-users
>
>



--
Marco Craveiro

MD, Domain Driven Consulting
about: http://about.me/marcocraveiro
blog: http://mcraveiro.blogspot.co.uk
twitter: https://twitter.com/MarcoCraveiro

That the Ideas are themselves manifestations (of the Idea-Idea) and
that the Idea-Idea is a-kind-of Manifestation-Idea—which is a-kind-of
itself, so that the system is completely self-describing— would have
been appreciated by Plato as an extremely practical joke [Plato]. --
Alan Key


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users
Loading...