|
From: Ben W. <ben...@ma...> - 2022-01-25 06:55:46
|
Thanks Luigi,
From: Luigi Ballabio <lui...@gm...>
Sent: Monday, 24 January 2022 8:52 PM
To: Ben Watson <ben...@ma...>
Cc: QuantLib users <qua...@li...>
Subject: Re: [Quantlib-users] Python Swaps - excluding cashflows on settlement date
Hello Ben,
the flag is exported, see <https://github.com/lballabio/QuantLib-SWIG/blob/master/SWIG/swap.i#L278>.
Writing `ql.DiscountingSwapEngine(yts, includeSettlementDateFlows)` should work.
`ql.Settings.instance().includeTodaysCashFlows = False` should also work if you want to set it once and for all.
Luigi
On Mon, Jan 24, 2022 at 10:42 AM Ben Watson <ben...@ma... <mailto:ben...@ma...> > wrote:
Hi,
I know that a few pricing engines can take includeSettlementDateFlows as a Boolean flag. I can seem to find an example of calling this with swap discount pricing engine.
I want to exclude settlement date cashflows. Without this flag, I would need to hack the code somewhat to generate cashflows from settlementdate +1.
Does ql.DiscountingSwapEngine(yts) have some undocumented flags, or ql.DiscountCurve some additional attributes that can be set to ignore settlement date flows?
Regards
Ben
_______________________________________________
QuantLib-users mailing list
Qua...@li... <mailto:Qua...@li...>
https://lists.sourceforge.net/lists/listinfo/quantlib-users
|