Re: Cashflows accrued methods
Posted by
Luigi Ballabio on
Oct 03, 2012; 3:11pm
URL: http://quantlib.414.s1.nabble.com/Cashflows-accrued-methods-tp9122p9123.html
Yes, you're right. Thanks for the heads-up.
Luigi
On Mon, Sep 17, 2012 at 10:06 PM, Peter Caspers <
[hidden email]> wrote:
> Hi Luigi, Nando,
>
> the methods Cashflows::accruedPeriod(), accruedDays() and accruedAmount()
> default the settlementDate to Date(), which I guess should mean to take the
> evaluation date as the settlement date. However this does not work with the
> methods in Coupon invoked from here. As a result 0.0 is returned always,
> when no settlement date is specified.
>
> I think therefore that
>
> if (settlementDate == Date())
> settlementDate = Settings::instance().evaluationDate();
>
> should be added to the methods mentioned above. I observe this in 1.1.
>
> Regards
> Peter
>
------------------------------------------------------------------------------
Don't let slow site performance ruin your business. Deploy New Relic APM
Deploy New Relic app performance management and know exactly
what is happening inside your Ruby, Python, PHP, Java, and .NET app
Try New Relic at no cost today and get our sweet Data Nerd shirt too!
http://p.sf.net/sfu/newrelic-dev2dev_______________________________________________
QuantLib-dev mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-dev