From: StephenWong <ste...@gm...> - 2011-10-30 12:46:11
|
Gavin08 wrote: > > > StephenWong wrote: >> >> Why are you comparing clean price with dirty price? >> qlBondCleanPriceFromYield calculates the price without accrued interests >> while PRICE from Excel includes that interests. No? >> > > Not true, PRICE excludes accrued interests too. In most of these examples, > the accrued interests are about 1 or 2 percentage points, i.e. the dirty > prices are about 101 or 102. > Nevermind about Excel, the help file has a wrong formula on it. Anyway if you just want to find out which results to trust, you can always work something out by hand. Since these are all fixed rate bonds, this should be easy. Just take the last two par bonds, change the maturity date to something shorter so that there will be like 4 or 5 months till maturity. Work it out by hand using dfraction = (no. of days till next coupon date) / (no. of days in coupon period) using the 30/360 convention of course Price = 100 * ( 1 + coupon rate/frequency * dfraction ) / ( 1 + yield / frequency )^dfraction. I got numbers that agree with quantlib and not Excel. -- View this message in context: http://old.nabble.com/Fixed-rate-bond-pricing-can-yield-different-results-compared-to-Excel%27s-built-in-functions-tp32733269p32746979.html Sent from the quantlib-users mailing list archive at Nabble.com. |