http://quantlib.414.s1.nabble.com/Do-we-really-need-to-pass-in-parameter-calendar-in-AmortizingFixedRateBond-tp15848p15901.html
Thanks for that information. Yes I may miss that part. I'll look into it.
主题: Re: [Quantlib-users] Do we really need to pass in parameter calendar in AmortizingFixedRateBond?
I'm not sure about it (it might as well be that we should also pass an adjustment convention to the sinkingSchedule function) but the calendar is used later for payment adjustment. The coupons are generated in sinkingSchedule() with Unadjusted convention, so the calendar is not used there, but it's stored into the returned schedule anyway. When FixedRateLeg is called, it will use the calendar stored in the schedule to adjust the payment date of the coupons with the convention passed in the withPaymentAdjustment() method.
> Hi Team,
>
>
>
> Currently AmortizingFixedRateBond’s second constructer function signature:
>
>
>
> Line 155: AmortizingFixedRateBond::AmortizingFixedRateBond(
>
> Natural settlementDays,
>
> const Calendar& calendar,
>
> Real initialFaceAmount,
>
> const Date& startDate,
>
> const Period& bondTenor,
>
> const Frequency&
> sinkingFrequency,
>
> const Rate coupon,
>
> const DayCounter&
> accrualDayCounter,
>
> BusinessDayConvention
> paymentConvention,
>
> const Date& issueDate)
>
>
>
> The second parameter calendar is used in sub function:
>
> Line 173: sinkingSchedule(startDate, bondTenor, sinkingFrequency,
> calendar)
>
>
>
> However as I see, in this function, the calendar is only used as:
>
>
>
> Line 104: Schedule retVal(startDate, maturityDate, freqPeriod,
>
> paymentCalendar, Unadjusted, Unadjusted,
>
> DateGeneration::Backward, false);
>
>
>
> As the convention is all passed as Unadjused, it seems paymentCalendar
> will have no any effect on generated retVal..
>
>
>
> Am I missing something here?
>
>
>
> Regards,
>
> Cheng
>
>
>
>
>
> Regards,
>
> Cheng
>
>
> ----------------------------------------------------------------------
> --------
> Want excitement?
> Manually upgrade your production database.
> When you want reliability, choose Perforce.
> Perforce version control. Predictably reliable.
>
http://pubads.g.doubleclick.net/gampad/clk?id=157508191&iu=/4140/ostg.
> clktrk _______________________________________________
> QuantLib-users mailing list
>
[hidden email]
>
https://lists.sourceforge.net/lists/listinfo/quantlib-users>
Slashdot TV. Video for Nerds. Stuff that Matters.