Re: QuantLib-users Digest, Vol 115, Issue 9

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Re: QuantLib-users Digest, Vol 115, Issue 9

Matt Slezak
Unsubscribe


On Tue, Dec 22, 2015 at 10:46 AM, [hidden email]
Send QuantLib-users mailing list submissions to
    <a ymailto="mailto:quantlib-users@lists.sourceforge.net" href="javascript:return">quantlib-users@...

To subscribe or unsubscribe via the World Wide Web, visit
    https://lists.sourceforge.net/lists/listinfo/quantlib-users
or, via email, send a message with subject or body 'help' to
    <a ymailto="mailto:quantlib-users-request@lists.sourceforge.net" href="javascript:return">quantlib-users-request@...

You can reach the person managing the list at
    <a ymailto="mailto:quantlib-users-owner@lists.sourceforge.net" href="javascript:return">quantlib-users-owner@...

When replying, please edit your Subject line so it is more specific
than "Re: Contents of QuantLib-users digest..."
Today's Topics:

  1. Re: Trouble about QuantLib-Python (Ruilong Xu)
  2. Bootstrapping yield curve by imposing implied    value = 0
      (Federico Cozzi)
  3. Re: Bootstrapping yield curve by imposing implied value = 0
      (Luigi Ballabio)
  4. Re: Swig Wrapers for DeltaVolQuote (Luigi Ballabio)
  5. Re: Swig Wrapers for DeltaVolQuote (DPaulino)
  6. Re: Swig Wrapers for DeltaVolQuote (Luigi Ballabio)
Thank You Very Much!
I have solved the trouble,maybe the reason is 'anaconda',anaconda makes
python as a part of itself,
so I can import QuantLib in anaconda,but I can not do the same thing in
python.



--
View this message in context: http://quantlib.10058.n7.nabble.com/Trouble-about-QuantLib-Python-tp17153p17198.html
Sent from the quantlib-users mailing list archive at Nabble.com.


Hello,
I would like to use Quantlib to bootstrap yield curves in a multi-curve
environment.

I read Ballabio's guide "Implementing Quantlib" and browsed source code. I
understand that IterativeBootstrap's algorithm, which relies on
BootstrapHelper, tries to equate market quote with implied quote.

I would like to use a slightly different approach: I would like to equate
the implied value with 0. The result should be the same, but code could be
simpler: for instance computing the swap value could be simpler that
computing the swap par rate.
(I see that Real SwapRateHelper::impliedQuote() contains the comment "weak
implementation... to be improved")

What is the easiest way to modify Quantlib code to perform this different
algorithm? Perhaps I could write my own RateHelpers, where I redefine the
quoteError method. But since IterativeBootstrap is quite general, perhaps
there is a better method.

Regards,
Federico Cozzi




Hi Federico,
    the easiest way might be to modify the rate helpers so that quoteError() returns the implied value. If you want to contribute the modifications, you'd also have to keep the old behavior, so you should add a boolean parameter or an enumeration to select the new or the old calculation.  This would allow you to reuse most of the current code.

Ferdinando, you wanted to work in this direction, too.  Any comments? (For instance, about extending this approach to other instruments such as deposits, FRAs or futures?)

Luigi


On Mon, Dec 21, 2015 at 11:02 AM Federico Cozzi <<a rel="nofollow" ymailto="mailto:f.cozzi@gmail.com" target="_blank" href="javascript:return">f.cozzi@...> wrote:
Hello,
I would like to use Quantlib to bootstrap yield curves in a multi-curve
environment.

I read Ballabio's guide "Implementing Quantlib" and browsed source code. I
understand that IterativeBootstrap's algorithm, which relies on
BootstrapHelper, tries to equate market quote with implied quote.

I would like to use a slightly different approach: I would like to equate
the implied value with 0. The result should be the same, but code could be
simpler: for instance computing the swap value could be simpler that
computing the swap par rate.
(I see that Real SwapRateHelper::impliedQuote() contains the comment "weak
implementation... to be improved")

What is the easiest way to modify Quantlib code to perform this different
algorithm? Perhaps I could write my own RateHelpers, where I redefine the
quoteError method. But since IterativeBootstrap is quite general, perhaps
there is a better method.

Regards,
Federico Cozzi


------------------------------------------------------------------------------
_______________________________________________
QuantLib-users mailing list
<a rel="nofollow" ymailto="mailto:QuantLib-users@lists.sourceforge.net" target="_blank" href="javascript:return">QuantLib-users@...
https://lists.sourceforge.net/lists/listinfo/quantlib-users
--

On Fri, Nov 27, 2015 at 4:05 PM DPaulino <<a rel="nofollow" ymailto="mailto:danielberen@gmail.com" target="_blank" href="javascript:return">danielberen@...> wrote:
Thank you Luigi!



--
View this message in context: http://quantlib.10058.n7.nabble.com/Swig-Wrapers-for-DeltaVolQuote-tp17124p17133.html
Sent from the quantlib-users mailing list archive at Nabble.com.

------------------------------------------------------------------------------
_______________________________________________
QuantLib-users mailing list
<a rel="nofollow" ymailto="mailto:QuantLib-users@lists.sourceforge.net" target="_blank" href="javascript:return">QuantLib-users@...
https://lists.sourceforge.net/lists/listinfo/quantlib-users
--
Sorry Luigi,

with these lines I seem to get the error:

Severity    Code    Description    Project    File    Line
Error    C2512    'QuantLib::DeltaVolQuote::DeltaVolQuote': no appropriate default
constructor available    NQuantLibc
C:\QuantLib-SWIG\CSharp\cpp\quantlib_wrap.cpp    80873

When I go to the refere line what I see is:

SWIGEXPORT void * SWIGSTDCALL CSharp_new__DeltaVolQuote() {
  void * jresult ;
  DeltaVolQuote *result = 0 ;
 
  {
    try {
      result = (DeltaVolQuote *)new DeltaVolQuote();
    } catch (std::out_of_range& e) {
      {
        SWIG_CSharpException(SWIG_IndexError, const_cast<char*>(e.what()));
return 0;
      };
    } catch (std::exception& e) {
      {
        SWIG_CSharpException(SWIG_RuntimeError,
const_cast<char*>(e.what())); return 0;
      };
    } catch (...) {
      {
        SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0;
      };
    }
  }
  jresult = (void *)result;
  return jresult;
}

Any ideas?



--
View this message in context: http://quantlib.10058.n7.nabble.com/Swig-Wrapers-for-DeltaVolQuote-tp17124p17203.html
Sent from the quantlib-users mailing list archive at Nabble.com.



Right. I hadn't tried Java. Adding https://github.com/lballabio/QuantLib-SWIG/commit/5465db3bf34bcb0600125322495c2d4c528cffc2 should  do the trick.

Luigi


On Tue, Dec 22, 2015 at 5:04 PM DPaulino <<a rel="nofollow" ymailto="mailto:danielberen@gmail.com" target="_blank" href="javascript:return">danielberen@...> wrote:
Sorry Luigi,

with these lines I seem to get the error:

Severity        Code    Description     Project File    Line
Error   C2512   'QuantLib::DeltaVolQuote::DeltaVolQuote': no appropriate default
constructor available   NQuantLibc
C:\QuantLib-SWIG\CSharp\cpp\quantlib_wrap.cpp   80873

When I go to the refere line what I see is:

SWIGEXPORT void * SWIGSTDCALL CSharp_new__DeltaVolQuote() {
  void * jresult ;
  DeltaVolQuote *result = 0 ;

  {
    try {
      result = (DeltaVolQuote *)new DeltaVolQuote();
    } catch (std::out_of_range& e) {
      {
        SWIG_CSharpException(SWIG_IndexError, const_cast<char*>(e.what()));
return 0;
      };
    } catch (std::exception& e) {
      {
        SWIG_CSharpException(SWIG_RuntimeError,
const_cast<char*>(e.what())); return 0;
      };
    } catch (...) {
      {
        SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0;
      };
    }
  }
  jresult = (void *)result;
  return jresult;
}

Any ideas?



--
View this message in context: http://quantlib.10058.n7.nabble.com/Swig-Wrapers-for-DeltaVolQuote-tp17124p17203.html
Sent from the quantlib-users mailing list archive at Nabble.com.

------------------------------------------------------------------------------
_______________________________________________
QuantLib-users mailing list
<a rel="nofollow" ymailto="mailto:QuantLib-users@lists.sourceforge.net" target="_blank" href="javascript:return">QuantLib-users@...
https://lists.sourceforge.net/lists/listinfo/quantlib-users
--
------------------------------------------------------------------------------
_______________________________________________
QuantLib-users mailing list
<a ymailto="mailto:QuantLib-users@lists.sourceforge.net" href="javascript:return">QuantLib-users@...
https://lists.sourceforge.net/lists/listinfo/quantlib-users

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

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