Hazard Rates Interpolator QLXL

classic Classic list List threaded Threaded
11 messages Options
Reply | Threaded
Open this post in threaded view
|

Hazard Rates Interpolator QLXL

Любовь Волкова
Hi everyone

i had a question regarding interpolator for hazard rates bootstrapping in qlxl. I use qlPiecewiseHazardRateCurve function and tried to pass interpolator as string ("BackwardFlat") as well as id of interpolator object created using qlInterpolation function. In both cases I get a failure message "Unrecognized interpolator". In which format should I pass the interpolation method?

Many thanks
Lyuba

------------------------------------------------------------------------------

_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users
Reply | Threaded
Open this post in threaded view
|

Re: Hazard Rates Interpolator QLXL

japari
Hello, sorry I did not see this one before.

Yes, it expects a text string for selecting the constructor. Can you check the case please?, it has to be upper case. "BACKWARDFLAT"
If that gives trouble, can you send a simple wsheet so I can debug it pls?
Best
pp


----- Original Message -----

>
>
>
> Hi everyone
>
>
> i had a question regarding interpolator for hazard rates
> bootstrapping in qlxl. I use qlPiecewiseHazardRateCurve function and
> tried to pass interpolator as string ("BackwardFlat") as well as id
> of interpolator object created using qlInterpolation function. In
> both cases I get a failure message "Unrecognized interpolator". In
> which format should I pass the interpolation method?
>
>
> Many thanks
> Lyuba
> ------------------------------------------------------------------------------
>
> _______________________________________________
> QuantLib-users mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/quantlib-users
>

------------------------------------------------------------------------------
Monitor 25 network devices or servers for free with OpManager!
OpManager is web-based network management software that monitors
network devices and physical & virtual servers, alerts via email & sms
for fault. Monitor 25 devices for free with no restriction. Download now
http://ad.doubleclick.net/ddm/clk/292181274;119417398;o
_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users
Reply | Threaded
Open this post in threaded view
|

Re: Hazard Rates Interpolator QLXL

Любовь Волкова
Hello, sorry for a late reply,

indeed with upper case works perfect :) Thanks a lot!

Kind regards,
Lyuba

2015-06-23 10:28 GMT+02:00 <[hidden email]>:
Hello, sorry I did not see this one before.

Yes, it expects a text string for selecting the constructor. Can you check the case please?, it has to be upper case. "BACKWARDFLAT"
If that gives trouble, can you send a simple wsheet so I can debug it pls?
Best
pp


----- Original Message -----
>
>
>
> Hi everyone
>
>
> i had a question regarding interpolator for hazard rates
> bootstrapping in qlxl. I use qlPiecewiseHazardRateCurve function and
> tried to pass interpolator as string ("BackwardFlat") as well as id
> of interpolator object created using qlInterpolation function. In
> both cases I get a failure message "Unrecognized interpolator". In
> which format should I pass the interpolation method?
>
>
> Many thanks
> Lyuba
> ------------------------------------------------------------------------------
>
> _______________________________________________
> QuantLib-users mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/quantlib-users
>


------------------------------------------------------------------------------

_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users
Reply | Threaded
Open this post in threaded view
|

Re: Hazard Rates Interpolator QLXL

japari
Au passage; there are a few worksheets in

QuantLibXL/StandaloneExamples/Credit
QuantLibXL/StandaloneExamples/CreditPortfolioRisk

that show how to call the credit functionality.

Best
Pepe


----- Original Message -----

>
>
>
> Hello, sorry for a late reply,
>
>
> indeed with upper case works perfect :) Thanks a lot!
>
>
> Kind regards,
> Lyuba
>
>
> 2015-06-23 10:28 GMT+02:00 < [hidden email] > :
>
>
> Hello, sorry I did not see this one before.
>
> Yes, it expects a text string for selecting the constructor. Can you
> check the case please?, it has to be upper case. "BACKWARDFLAT"
> If that gives trouble, can you send a simple wsheet so I can debug it
> pls?
> Best
> pp
>
>
>
>
> ----- Original Message -----
> >
> >
> >
> > Hi everyone
> >
> >
> > i had a question regarding interpolator for hazard rates
> > bootstrapping in qlxl. I use qlPiecewiseHazardRateCurve function
> > and
> > tried to pass interpolator as string ("BackwardFlat") as well as id
> > of interpolator object created using qlInterpolation function. In
> > both cases I get a failure message "Unrecognized interpolator". In
> > which format should I pass the interpolation method?
> >
> >
> > Many thanks
> > Lyuba
> > ------------------------------------------------------------------------------
> >
> > _______________________________________________
> > QuantLib-users mailing list
> > [hidden email]
> > https://lists.sourceforge.net/lists/listinfo/quantlib-users
> >
>
>
> ------------------------------------------------------------------------------
>
> _______________________________________________
> QuantLib-users mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/quantlib-users
>

------------------------------------------------------------------------------
_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users
Reply | Threaded
Open this post in threaded view
|

Re: Hazard Rates Interpolator QLXL

Peter Caspers-4
Pepe, I seem to remember that those string tags in QLXL are case
insensitive in general (stop me if I am talking nonsense), so maybe
this should apply to the credit part as well ? Also, is there a
complete list of allowed tags (except in the enumerated something
files themselves ?) - I guess it would be nice to have them available
in one place in some public doc ?
Peter

On 18 August 2015 at 21:57,  <[hidden email]> wrote:

> Au passage; there are a few worksheets in
>
> QuantLibXL/StandaloneExamples/Credit
> QuantLibXL/StandaloneExamples/CreditPortfolioRisk
>
> that show how to call the credit functionality.
>
> Best
> Pepe
>
>
> ----- Original Message -----
>>
>>
>>
>> Hello, sorry for a late reply,
>>
>>
>> indeed with upper case works perfect :) Thanks a lot!
>>
>>
>> Kind regards,
>> Lyuba
>>
>>
>> 2015-06-23 10:28 GMT+02:00 < [hidden email] > :
>>
>>
>> Hello, sorry I did not see this one before.
>>
>> Yes, it expects a text string for selecting the constructor. Can you
>> check the case please?, it has to be upper case. "BACKWARDFLAT"
>> If that gives trouble, can you send a simple wsheet so I can debug it
>> pls?
>> Best
>> pp
>>
>>
>>
>>
>> ----- Original Message -----
>> >
>> >
>> >
>> > Hi everyone
>> >
>> >
>> > i had a question regarding interpolator for hazard rates
>> > bootstrapping in qlxl. I use qlPiecewiseHazardRateCurve function
>> > and
>> > tried to pass interpolator as string ("BackwardFlat") as well as id
>> > of interpolator object created using qlInterpolation function. In
>> > both cases I get a failure message "Unrecognized interpolator". In
>> > which format should I pass the interpolation method?
>> >
>> >
>> > Many thanks
>> > Lyuba
>> > ------------------------------------------------------------------------------
>> >
>> > _______________________________________________
>> > QuantLib-users mailing list
>> > [hidden email]
>> > https://lists.sourceforge.net/lists/listinfo/quantlib-users
>> >
>>
>>
>> ------------------------------------------------------------------------------
>>
>> _______________________________________________
>> QuantLib-users mailing list
>> [hidden email]
>> https://lists.sourceforge.net/lists/listinfo/quantlib-users
>>
>
> ------------------------------------------------------------------------------
> _______________________________________________
> QuantLib-users mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/quantlib-users

------------------------------------------------------------------------------
_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users
Reply | Threaded
Open this post in threaded view
|

Re: Hazard Rates Interpolator QLXL

japari
Hi,
The proper way to do it is what you imply; A factory linked to a tag to resolve the template parameter. I haven’t done that and resolve it in the code, but its true I could have compared in a case independent way......

from QuantLibAddin/qlo/credit.cpp #256:

    PiecewiseHazardRateCurve::PiecewiseHazardRateCurve(
            const boost::shared_ptr<ObjectHandler::ValueObject>& properties,
            const std::vector<boost::shared_ptr<QuantLib::DefaultProbabilityHelper> >& helpers,
            const QuantLib::DayCounter& dayCounter,
            const QuantLib::Calendar& calendar,
            const std::string& interpolator,
            QuantLib::Real accuracy,
            bool permanent)
        : DefaultProbabilityTermStructure(properties, permanent) {

        if(interpolator == std::string("LINEAR")){
            libraryObject_ = boost::shared_ptr<QuantLib::Extrapolator>(new
                   QuantLib::PiecewiseDefaultCurve<QuantLib::HazardRate,
                        QuantLib::Linear>(
                            0,
                            calendar,
                            helpers,
                            dayCounter));
        }else if(interpolator == std::string("BACKWARDFLAT")) {
            libraryObject_ = boost::shared_ptr<QuantLib::Extrapolator>(new
                   QuantLib::PiecewiseDefaultCurve<QuantLib::HazardRate,
                        QuantLib::BackwardFlat>(
                            0,
                            calendar,
                            helpers,
                            dayCounter));
        }else{
            QL_FAIL("Unrecognised interpolator");
        }

        libraryObject_->enableExtrapolation();
    }

Best
Pepe


----- Original Message -----

> Pepe, I seem to remember that those string tags in QLXL are case
> insensitive in general (stop me if I am talking nonsense), so maybe
> this should apply to the credit part as well ? Also, is there a
> complete list of allowed tags (except in the enumerated something
> files themselves ?) - I guess it would be nice to have them available
> in one place in some public doc ?
> Peter
>
> On 18 August 2015 at 21:57,  <[hidden email]> wrote:
> > Au passage; there are a few worksheets in
> >
> > QuantLibXL/StandaloneExamples/Credit
> > QuantLibXL/StandaloneExamples/CreditPortfolioRisk
> >
> > that show how to call the credit functionality.
> >
> > Best
> > Pepe
> >
> >
> > ----- Original Message -----
> >>
> >>
> >>
> >> Hello, sorry for a late reply,
> >>
> >>
> >> indeed with upper case works perfect :) Thanks a lot!
> >>
> >>
> >> Kind regards,
> >> Lyuba
> >>
> >>
> >> 2015-06-23 10:28 GMT+02:00 < [hidden email] > :
> >>
> >>
> >> Hello, sorry I did not see this one before.
> >>
> >> Yes, it expects a text string for selecting the constructor. Can
> >> you
> >> check the case please?, it has to be upper case. "BACKWARDFLAT"
> >> If that gives trouble, can you send a simple wsheet so I can debug
> >> it
> >> pls?
> >> Best
> >> pp
> >>
> >>
> >>
> >>
> >> ----- Original Message -----
> >> >
> >> >
> >> >
> >> > Hi everyone
> >> >
> >> >
> >> > i had a question regarding interpolator for hazard rates
> >> > bootstrapping in qlxl. I use qlPiecewiseHazardRateCurve function
> >> > and
> >> > tried to pass interpolator as string ("BackwardFlat") as well as
> >> > id
> >> > of interpolator object created using qlInterpolation function.
> >> > In
> >> > both cases I get a failure message "Unrecognized interpolator".
> >> > In
> >> > which format should I pass the interpolation method?
> >> >
> >> >
> >> > Many thanks
> >> > Lyuba
> >> > ------------------------------------------------------------------------------
> >> >
> >> > _______________________________________________
> >> > QuantLib-users mailing list
> >> > [hidden email]
> >> > https://lists.sourceforge.net/lists/listinfo/quantlib-users
> >> >
> >>
> >>
> >> ------------------------------------------------------------------------------
> >>
> >> _______________________________________________
> >> QuantLib-users mailing list
> >> [hidden email]
> >> https://lists.sourceforge.net/lists/listinfo/quantlib-users
> >>
> >
> > ------------------------------------------------------------------------------
> > _______________________________________________
> > QuantLib-users mailing list
> > [hidden email]
> > https://lists.sourceforge.net/lists/listinfo/quantlib-users
>

------------------------------------------------------------------------------
_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users
Reply | Threaded
Open this post in threaded view
|

Re: Hazard Rates Interpolator QLXL

japari
In reply to this post by Peter Caspers-4
Actually I did not answer your question. Theres a list...in the factories source code... :-)
But this would be a list per class template and sometimes (like in this case) there are several template parameters so it wouldnt be as simple as an index.
In this case you dont want an interpolator object but a term structure that is indexed by an interpolation type and a few other types (1 in this case, the HazardRate/Probability/...)

Best
Pepe

----- Original Message -----

> Pepe, I seem to remember that those string tags in QLXL are case
> insensitive in general (stop me if I am talking nonsense), so maybe
> this should apply to the credit part as well ? Also, is there a
> complete list of allowed tags (except in the enumerated something
> files themselves ?) - I guess it would be nice to have them available
> in one place in some public doc ?
> Peter
>
> On 18 August 2015 at 21:57,  <[hidden email]> wrote:
> > Au passage; there are a few worksheets in
> >
> > QuantLibXL/StandaloneExamples/Credit
> > QuantLibXL/StandaloneExamples/CreditPortfolioRisk
> >
> > that show how to call the credit functionality.
> >
> > Best
> > Pepe
> >
> >
> > ----- Original Message -----
> >>
> >>
> >>
> >> Hello, sorry for a late reply,
> >>
> >>
> >> indeed with upper case works perfect :) Thanks a lot!
> >>
> >>
> >> Kind regards,
> >> Lyuba
> >>
> >>
> >> 2015-06-23 10:28 GMT+02:00 < [hidden email] > :
> >>
> >>
> >> Hello, sorry I did not see this one before.
> >>
> >> Yes, it expects a text string for selecting the constructor. Can
> >> you
> >> check the case please?, it has to be upper case. "BACKWARDFLAT"
> >> If that gives trouble, can you send a simple wsheet so I can debug
> >> it
> >> pls?
> >> Best
> >> pp
> >>
> >>
> >>
> >>
> >> ----- Original Message -----
> >> >
> >> >
> >> >
> >> > Hi everyone
> >> >
> >> >
> >> > i had a question regarding interpolator for hazard rates
> >> > bootstrapping in qlxl. I use qlPiecewiseHazardRateCurve function
> >> > and
> >> > tried to pass interpolator as string ("BackwardFlat") as well as
> >> > id
> >> > of interpolator object created using qlInterpolation function.
> >> > In
> >> > both cases I get a failure message "Unrecognized interpolator".
> >> > In
> >> > which format should I pass the interpolation method?
> >> >
> >> >
> >> > Many thanks
> >> > Lyuba
> >> > ------------------------------------------------------------------------------
> >> >
> >> > _______________________________________________
> >> > QuantLib-users mailing list
> >> > [hidden email]
> >> > https://lists.sourceforge.net/lists/listinfo/quantlib-users
> >> >
> >>
> >>
> >> ------------------------------------------------------------------------------
> >>
> >> _______________________________________________
> >> QuantLib-users mailing list
> >> [hidden email]
> >> https://lists.sourceforge.net/lists/listinfo/quantlib-users
> >>
> >
> > ------------------------------------------------------------------------------
> > _______________________________________________
> > QuantLib-users mailing list
> > [hidden email]
> > https://lists.sourceforge.net/lists/listinfo/quantlib-users
>

------------------------------------------------------------------------------
_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users
Reply | Threaded
Open this post in threaded view
|

Re: Hazard Rates Interpolator QLXL

Peter Caspers-4
yes, that's where I used to look them up :-) I guess it would pay out
for many users to have them documented properly. At best they would be
available in the wizard's help message in their exact form. It's a
pity to have all this great functionality, but no transparency on how
to access it, at least for black box users. Which reminds me of my
Numerix / Excel days with quite similar problems ... :-/


On 19 August 2015 at 09:54,  <[hidden email]> wrote:

> Actually I did not answer your question. Theres a list...in the factories source code... :-)
> But this would be a list per class template and sometimes (like in this case) there are several template parameters so it wouldnt be as simple as an index.
> In this case you dont want an interpolator object but a term structure that is indexed by an interpolation type and a few other types (1 in this case, the HazardRate/Probability/...)
>
> Best
> Pepe
>
> ----- Original Message -----
>> Pepe, I seem to remember that those string tags in QLXL are case
>> insensitive in general (stop me if I am talking nonsense), so maybe
>> this should apply to the credit part as well ? Also, is there a
>> complete list of allowed tags (except in the enumerated something
>> files themselves ?) - I guess it would be nice to have them available
>> in one place in some public doc ?
>> Peter
>>
>> On 18 August 2015 at 21:57,  <[hidden email]> wrote:
>> > Au passage; there are a few worksheets in
>> >
>> > QuantLibXL/StandaloneExamples/Credit
>> > QuantLibXL/StandaloneExamples/CreditPortfolioRisk
>> >
>> > that show how to call the credit functionality.
>> >
>> > Best
>> > Pepe
>> >
>> >
>> > ----- Original Message -----
>> >>
>> >>
>> >>
>> >> Hello, sorry for a late reply,
>> >>
>> >>
>> >> indeed with upper case works perfect :) Thanks a lot!
>> >>
>> >>
>> >> Kind regards,
>> >> Lyuba
>> >>
>> >>
>> >> 2015-06-23 10:28 GMT+02:00 < [hidden email] > :
>> >>
>> >>
>> >> Hello, sorry I did not see this one before.
>> >>
>> >> Yes, it expects a text string for selecting the constructor. Can
>> >> you
>> >> check the case please?, it has to be upper case. "BACKWARDFLAT"
>> >> If that gives trouble, can you send a simple wsheet so I can debug
>> >> it
>> >> pls?
>> >> Best
>> >> pp
>> >>
>> >>
>> >>
>> >>
>> >> ----- Original Message -----
>> >> >
>> >> >
>> >> >
>> >> > Hi everyone
>> >> >
>> >> >
>> >> > i had a question regarding interpolator for hazard rates
>> >> > bootstrapping in qlxl. I use qlPiecewiseHazardRateCurve function
>> >> > and
>> >> > tried to pass interpolator as string ("BackwardFlat") as well as
>> >> > id
>> >> > of interpolator object created using qlInterpolation function.
>> >> > In
>> >> > both cases I get a failure message "Unrecognized interpolator".
>> >> > In
>> >> > which format should I pass the interpolation method?
>> >> >
>> >> >
>> >> > Many thanks
>> >> > Lyuba
>> >> > ------------------------------------------------------------------------------
>> >> >
>> >> > _______________________________________________
>> >> > QuantLib-users mailing list
>> >> > [hidden email]
>> >> > https://lists.sourceforge.net/lists/listinfo/quantlib-users
>> >> >
>> >>
>> >>
>> >> ------------------------------------------------------------------------------
>> >>
>> >> _______________________________________________
>> >> QuantLib-users mailing list
>> >> [hidden email]
>> >> https://lists.sourceforge.net/lists/listinfo/quantlib-users
>> >>
>> >
>> > ------------------------------------------------------------------------------
>> > _______________________________________________
>> > QuantLib-users mailing list
>> > [hidden email]
>> > https://lists.sourceforge.net/lists/listinfo/quantlib-users
>>

------------------------------------------------------------------------------
_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users
Reply | Threaded
Open this post in threaded view
|

Re: Hazard Rates Interpolator QLXL

Eric Ehlers-3
Hi All,

I just had a very cursory look at things.  In the enumerations the
identifier BackwardFlat appears twice:

http://quantlib.org/quantlibaddin/enums.html

In those contexts the strings are case insensitive, and are documented.

It appears that in the case of credit the string "BACKWARDFLAT" is hard
coded into the source code:

https://github.com/eehlers/quantlib/blob/master/QuantLibAddin/qlo/credit.cpp

So in that case it would not work like the other enumerations.

Off the top of my head I am pretty sure that it would be possible to
use the enumerations for credit.  The mechanism is pretty flexible and
we used it for example to map strings to C++ template classes.

Kind Regards,
Eric

On Wed, 19 Aug 2015 10:10:22 +0200
Peter Caspers <[hidden email]> wrote:

> yes, that's where I used to look them up :-) I guess it would pay out
> for many users to have them documented properly. At best they would be
> available in the wizard's help message in their exact form. It's a
> pity to have all this great functionality, but no transparency on how
> to access it, at least for black box users. Which reminds me of my
> Numerix / Excel days with quite similar problems ... :-/
>
>
> On 19 August 2015 at 09:54,  <[hidden email]> wrote:
> > Actually I did not answer your question. Theres a list...in the
> > factories source code... :-) But this would be a list per class
> > template and sometimes (like in this case) there are several
> > template parameters so it wouldnt be as simple as an index. In this
> > case you dont want an interpolator object but a term structure that
> > is indexed by an interpolation type and a few other types (1 in
> > this case, the HazardRate/Probability/...)
> >
> > Best
> > Pepe
> >
> > ----- Original Message -----
> >> Pepe, I seem to remember that those string tags in QLXL are case
> >> insensitive in general (stop me if I am talking nonsense), so maybe
> >> this should apply to the credit part as well ? Also, is there a
> >> complete list of allowed tags (except in the enumerated something
> >> files themselves ?) - I guess it would be nice to have them
> >> available in one place in some public doc ?
> >> Peter
> >>
> >> On 18 August 2015 at 21:57,  <[hidden email]> wrote:
> >> > Au passage; there are a few worksheets in
> >> >
> >> > QuantLibXL/StandaloneExamples/Credit
> >> > QuantLibXL/StandaloneExamples/CreditPortfolioRisk
> >> >
> >> > that show how to call the credit functionality.
> >> >
> >> > Best
> >> > Pepe
> >> >
> >> >
> >> > ----- Original Message -----
> >> >>
> >> >>
> >> >>
> >> >> Hello, sorry for a late reply,
> >> >>
> >> >>
> >> >> indeed with upper case works perfect :) Thanks a lot!
> >> >>
> >> >>
> >> >> Kind regards,
> >> >> Lyuba
> >> >>
> >> >>
> >> >> 2015-06-23 10:28 GMT+02:00 < [hidden email] > :
> >> >>
> >> >>
> >> >> Hello, sorry I did not see this one before.
> >> >>
> >> >> Yes, it expects a text string for selecting the constructor. Can
> >> >> you
> >> >> check the case please?, it has to be upper case. "BACKWARDFLAT"
> >> >> If that gives trouble, can you send a simple wsheet so I can
> >> >> debug it
> >> >> pls?
> >> >> Best
> >> >> pp
> >> >>
> >> >>
> >> >>
> >> >>
> >> >> ----- Original Message -----
> >> >> >
> >> >> >
> >> >> >
> >> >> > Hi everyone
> >> >> >
> >> >> >
> >> >> > i had a question regarding interpolator for hazard rates
> >> >> > bootstrapping in qlxl. I use qlPiecewiseHazardRateCurve
> >> >> > function and
> >> >> > tried to pass interpolator as string ("BackwardFlat") as well
> >> >> > as id
> >> >> > of interpolator object created using qlInterpolation function.
> >> >> > In
> >> >> > both cases I get a failure message "Unrecognized
> >> >> > interpolator". In
> >> >> > which format should I pass the interpolation method?
> >> >> >
> >> >> >
> >> >> > Many thanks
> >> >> > Lyuba
> >> >> > ------------------------------------------------------------------------------
> >> >> >
> >> >> > _______________________________________________
> >> >> > QuantLib-users mailing list
> >> >> > [hidden email]
> >> >> > https://lists.sourceforge.net/lists/listinfo/quantlib-users
> >> >> >
> >> >>
> >> >>
> >> >> ------------------------------------------------------------------------------
> >> >>
> >> >> _______________________________________________
> >> >> QuantLib-users mailing list
> >> >> [hidden email]
> >> >> https://lists.sourceforge.net/lists/listinfo/quantlib-users
> >> >>
> >> >
> >> > ------------------------------------------------------------------------------
> >> > _______________________________________________
> >> > QuantLib-users mailing list
> >> > [hidden email]
> >> > https://lists.sourceforge.net/lists/listinfo/quantlib-users
> >>
>
> ------------------------------------------------------------------------------
> _______________________________________________
> QuantLib-users mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/quantlib-users


------------------------------------------------------------------------------
_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users
Reply | Threaded
Open this post in threaded view
|

Re: Hazard Rates Interpolator QLXL

japari
OK, thanks for the pointers. I will work on it.
Best
Pepe


----- Original Message -----

> Hi All,
>
> I just had a very cursory look at things.  In the enumerations the
> identifier BackwardFlat appears twice:
>
> http://quantlib.org/quantlibaddin/enums.html
>
> In those contexts the strings are case insensitive, and are
> documented.
>
> It appears that in the case of credit the string "BACKWARDFLAT" is
> hard
> coded into the source code:
>
> https://github.com/eehlers/quantlib/blob/master/QuantLibAddin/qlo/credit.cpp
>
> So in that case it would not work like the other enumerations.
>
> Off the top of my head I am pretty sure that it would be possible to
> use the enumerations for credit.  The mechanism is pretty flexible
> and
> we used it for example to map strings to C++ template classes.
>
> Kind Regards,
> Eric
>
> On Wed, 19 Aug 2015 10:10:22 +0200
> Peter Caspers <[hidden email]> wrote:
>
> > yes, that's where I used to look them up :-) I guess it would pay
> > out
> > for many users to have them documented properly. At best they would
> > be
> > available in the wizard's help message in their exact form. It's a
> > pity to have all this great functionality, but no transparency on
> > how
> > to access it, at least for black box users. Which reminds me of my
> > Numerix / Excel days with quite similar problems ... :-/
> >
> >
> > On 19 August 2015 at 09:54,  <[hidden email]> wrote:
> > > Actually I did not answer your question. Theres a list...in the
> > > factories source code... :-) But this would be a list per class
> > > template and sometimes (like in this case) there are several
> > > template parameters so it wouldnt be as simple as an index. In
> > > this
> > > case you dont want an interpolator object but a term structure
> > > that
> > > is indexed by an interpolation type and a few other types (1 in
> > > this case, the HazardRate/Probability/...)
> > >
> > > Best
> > > Pepe
> > >
> > > ----- Original Message -----
> > >> Pepe, I seem to remember that those string tags in QLXL are case
> > >> insensitive in general (stop me if I am talking nonsense), so
> > >> maybe
> > >> this should apply to the credit part as well ? Also, is there a
> > >> complete list of allowed tags (except in the enumerated
> > >> something
> > >> files themselves ?) - I guess it would be nice to have them
> > >> available in one place in some public doc ?
> > >> Peter
> > >>
> > >> On 18 August 2015 at 21:57,  <[hidden email]> wrote:
> > >> > Au passage; there are a few worksheets in
> > >> >
> > >> > QuantLibXL/StandaloneExamples/Credit
> > >> > QuantLibXL/StandaloneExamples/CreditPortfolioRisk
> > >> >
> > >> > that show how to call the credit functionality.
> > >> >
> > >> > Best
> > >> > Pepe
> > >> >
> > >> >
> > >> > ----- Original Message -----
> > >> >>
> > >> >>
> > >> >>
> > >> >> Hello, sorry for a late reply,
> > >> >>
> > >> >>
> > >> >> indeed with upper case works perfect :) Thanks a lot!
> > >> >>
> > >> >>
> > >> >> Kind regards,
> > >> >> Lyuba
> > >> >>
> > >> >>
> > >> >> 2015-06-23 10:28 GMT+02:00 < [hidden email] > :
> > >> >>
> > >> >>
> > >> >> Hello, sorry I did not see this one before.
> > >> >>
> > >> >> Yes, it expects a text string for selecting the constructor.
> > >> >> Can
> > >> >> you
> > >> >> check the case please?, it has to be upper case.
> > >> >> "BACKWARDFLAT"
> > >> >> If that gives trouble, can you send a simple wsheet so I can
> > >> >> debug it
> > >> >> pls?
> > >> >> Best
> > >> >> pp
> > >> >>
> > >> >>
> > >> >>
> > >> >>
> > >> >> ----- Original Message -----
> > >> >> >
> > >> >> >
> > >> >> >
> > >> >> > Hi everyone
> > >> >> >
> > >> >> >
> > >> >> > i had a question regarding interpolator for hazard rates
> > >> >> > bootstrapping in qlxl. I use qlPiecewiseHazardRateCurve
> > >> >> > function and
> > >> >> > tried to pass interpolator as string ("BackwardFlat") as
> > >> >> > well
> > >> >> > as id
> > >> >> > of interpolator object created using qlInterpolation
> > >> >> > function.
> > >> >> > In
> > >> >> > both cases I get a failure message "Unrecognized
> > >> >> > interpolator". In
> > >> >> > which format should I pass the interpolation method?
> > >> >> >
> > >> >> >
> > >> >> > Many thanks
> > >> >> > Lyuba
> > >> >> > ------------------------------------------------------------------------------
> > >> >> >
> > >> >> > _______________________________________________
> > >> >> > QuantLib-users mailing list
> > >> >> > [hidden email]
> > >> >> > https://lists.sourceforge.net/lists/listinfo/quantlib-users
> > >> >> >
> > >> >>
> > >> >>
> > >> >> ------------------------------------------------------------------------------
> > >> >>
> > >> >> _______________________________________________
> > >> >> QuantLib-users mailing list
> > >> >> [hidden email]
> > >> >> https://lists.sourceforge.net/lists/listinfo/quantlib-users
> > >> >>
> > >> >
> > >> > ------------------------------------------------------------------------------
> > >> > _______________________________________________
> > >> > QuantLib-users mailing list
> > >> > [hidden email]
> > >> > https://lists.sourceforge.net/lists/listinfo/quantlib-users
> > >>
> >
> > ------------------------------------------------------------------------------
> > _______________________________________________
> > QuantLib-users mailing list
> > [hidden email]
> > https://lists.sourceforge.net/lists/listinfo/quantlib-users
>
>

------------------------------------------------------------------------------
_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users
Reply | Threaded
Open this post in threaded view
|

Re: Hazard Rates Interpolator QLXL

Eric Ehlers-3
Cool!

>From memory there is something in there where this...

    qlFoo("A", "B")

...maps to this:

    template <class A, class B>
    class Foo { /* ... */ };

I am pretty sure it was yield curves.

Cheers,
Eric

On Wed, 19 Aug 2015 13:24:08 +0200 (CEST)
[hidden email] wrote:

> OK, thanks for the pointers. I will work on it.
> Best
> Pepe
>
>
> ----- Original Message -----
> > Hi All,
> >
> > I just had a very cursory look at things.  In the enumerations the
> > identifier BackwardFlat appears twice:
> >
> > http://quantlib.org/quantlibaddin/enums.html
> >
> > In those contexts the strings are case insensitive, and are
> > documented.
> >
> > It appears that in the case of credit the string "BACKWARDFLAT" is
> > hard
> > coded into the source code:
> >
> > https://github.com/eehlers/quantlib/blob/master/QuantLibAddin/qlo/credit.cpp
> >
> > So in that case it would not work like the other enumerations.
> >
> > Off the top of my head I am pretty sure that it would be possible to
> > use the enumerations for credit.  The mechanism is pretty flexible
> > and
> > we used it for example to map strings to C++ template classes.
> >
> > Kind Regards,
> > Eric
> >
> > On Wed, 19 Aug 2015 10:10:22 +0200
> > Peter Caspers <[hidden email]> wrote:
> >
> > > yes, that's where I used to look them up :-) I guess it would pay
> > > out
> > > for many users to have them documented properly. At best they
> > > would be
> > > available in the wizard's help message in their exact form. It's a
> > > pity to have all this great functionality, but no transparency on
> > > how
> > > to access it, at least for black box users. Which reminds me of my
> > > Numerix / Excel days with quite similar problems ... :-/
> > >
> > >
> > > On 19 August 2015 at 09:54,  <[hidden email]> wrote:
> > > > Actually I did not answer your question. Theres a list...in the
> > > > factories source code... :-) But this would be a list per class
> > > > template and sometimes (like in this case) there are several
> > > > template parameters so it wouldnt be as simple as an index. In
> > > > this
> > > > case you dont want an interpolator object but a term structure
> > > > that
> > > > is indexed by an interpolation type and a few other types (1 in
> > > > this case, the HazardRate/Probability/...)
> > > >
> > > > Best
> > > > Pepe
> > > >
> > > > ----- Original Message -----
> > > >> Pepe, I seem to remember that those string tags in QLXL are
> > > >> case insensitive in general (stop me if I am talking
> > > >> nonsense), so maybe
> > > >> this should apply to the credit part as well ? Also, is there a
> > > >> complete list of allowed tags (except in the enumerated
> > > >> something
> > > >> files themselves ?) - I guess it would be nice to have them
> > > >> available in one place in some public doc ?
> > > >> Peter
> > > >>
> > > >> On 18 August 2015 at 21:57,  <[hidden email]> wrote:
> > > >> > Au passage; there are a few worksheets in
> > > >> >
> > > >> > QuantLibXL/StandaloneExamples/Credit
> > > >> > QuantLibXL/StandaloneExamples/CreditPortfolioRisk
> > > >> >
> > > >> > that show how to call the credit functionality.
> > > >> >
> > > >> > Best
> > > >> > Pepe
> > > >> >
> > > >> >
> > > >> > ----- Original Message -----
> > > >> >>
> > > >> >>
> > > >> >>
> > > >> >> Hello, sorry for a late reply,
> > > >> >>
> > > >> >>
> > > >> >> indeed with upper case works perfect :) Thanks a lot!
> > > >> >>
> > > >> >>
> > > >> >> Kind regards,
> > > >> >> Lyuba
> > > >> >>
> > > >> >>
> > > >> >> 2015-06-23 10:28 GMT+02:00 < [hidden email] > :
> > > >> >>
> > > >> >>
> > > >> >> Hello, sorry I did not see this one before.
> > > >> >>
> > > >> >> Yes, it expects a text string for selecting the constructor.
> > > >> >> Can
> > > >> >> you
> > > >> >> check the case please?, it has to be upper case.
> > > >> >> "BACKWARDFLAT"
> > > >> >> If that gives trouble, can you send a simple wsheet so I can
> > > >> >> debug it
> > > >> >> pls?
> > > >> >> Best
> > > >> >> pp
> > > >> >>
> > > >> >>
> > > >> >>
> > > >> >>
> > > >> >> ----- Original Message -----
> > > >> >> >
> > > >> >> >
> > > >> >> >
> > > >> >> > Hi everyone
> > > >> >> >
> > > >> >> >
> > > >> >> > i had a question regarding interpolator for hazard rates
> > > >> >> > bootstrapping in qlxl. I use qlPiecewiseHazardRateCurve
> > > >> >> > function and
> > > >> >> > tried to pass interpolator as string ("BackwardFlat") as
> > > >> >> > well
> > > >> >> > as id
> > > >> >> > of interpolator object created using qlInterpolation
> > > >> >> > function.
> > > >> >> > In
> > > >> >> > both cases I get a failure message "Unrecognized
> > > >> >> > interpolator". In
> > > >> >> > which format should I pass the interpolation method?
> > > >> >> >
> > > >> >> >
> > > >> >> > Many thanks
> > > >> >> > Lyuba
> > > >> >> > ------------------------------------------------------------------------------
> > > >> >> >
> > > >> >> > _______________________________________________
> > > >> >> > QuantLib-users mailing list
> > > >> >> > [hidden email]
> > > >> >> > https://lists.sourceforge.net/lists/listinfo/quantlib-users
> > > >> >> >
> > > >> >>
> > > >> >>
> > > >> >> ------------------------------------------------------------------------------
> > > >> >>
> > > >> >> _______________________________________________
> > > >> >> QuantLib-users mailing list
> > > >> >> [hidden email]
> > > >> >> https://lists.sourceforge.net/lists/listinfo/quantlib-users
> > > >> >>
> > > >> >
> > > >> > ------------------------------------------------------------------------------
> > > >> > _______________________________________________
> > > >> > QuantLib-users mailing list
> > > >> > [hidden email]
> > > >> > https://lists.sourceforge.net/lists/listinfo/quantlib-users
> > > >>
> > >
> > > ------------------------------------------------------------------------------
> > > _______________________________________________
> > > QuantLib-users mailing list
> > > [hidden email]
> > > https://lists.sourceforge.net/lists/listinfo/quantlib-users
> >
> >


------------------------------------------------------------------------------
_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users