Re: Yield Curve Interpolation - Bug?

Posted by Luigi Ballabio on
URL: http://quantlib.414.s1.nabble.com/Yield-Curve-Interpolation-Bug-tp5822p5824.html

On Tue, 2008-03-18 at 15:23 -0700, tibbar wrote:

> DayCounter dayCount = SimpleDayCounter();
>
> for(int i = 1; i <= 17; i++){
> Real interestRate = termStructure->zeroRate((Real) i, Compounded);
> cout << "Time " << i << " discount factor " << interestRate << '\n';
> }

Tibbar,
        you'll probably need to use Actual365Fixed() as the day count,
otherwise the date today+365*i won't correspond to the time (Real) i.

Luigi


--

Newton's Law of Gravitation:
What goes up must come down. But don't expect it to come down
where you can find it. Murphy's Law applies to Newton's.



-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users