The ACCRFRAC command does not work properly and gives me an error when the input argument "Basis" is set to 6:
accrfrac('12/5/2004','1/29/2009',1,6,1)
??? Index exceeds matrix dimensions. Error in ==> dateoffset at 185 CpnDay(LookupIndex) = DayTable(DayTableIndex); Error in ==> cpndatep at 158 [CpnDay, CpnMonth, CpnYear] = dateoffset(referenceDate(:,3), referenceDate(:,2), ... Error in ==> accrfrac at 96 PreviousCouponDate = cpndatep(Settle, Maturity, Period, Basis, ...
Best Answer