Closed DominicHong closed 2 years ago
Hi - I don't understand how that is accrued interest ? Isn't that just a capital gain ?
Of course you can count it as capital gain. But it's considered interest in accounting, at least it's the convention in China. Two considerations: 1, This 'capital gain' increases day by day just as the interest does. On the other hand, the normal coupon is paid only on payment days, just as the capital gain of a zero bond on the maturity day. So capital gain can be interest and interest can be capital gain. They are the same. 2, The trade system ususally uses the same quote convention for both zero bonds and bonds with coupon. The price is quoted in clean price. It would be strange to always have no accrued interest for a clean price.
------------------ Original ------------------ From: "domokane/FinancePy" @.>; Date: Tue, Sep 27, 2022 05:38 PM @.>; @.**@.>; Subject: Re: [domokane/FinancePy] Calculate the accrued interest of the Zero Coupon Bond (PR #146)
Hi - I don't understand how that is accrued interest ? Isn't that just a capital gain ?
— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>
Sounds reasonable. How about a subclass of Bond?
Hi, I've created the new BondZero class. Please check it out.
Great! I think it looks good and keeps the bond class cleaner and the design simple. I have checked it and merged it. I will do some more checking later.
Zero Coupon Bonds now have accrued interest.
Added issue_price to Bond.init() Modified Bond.calc_accrued_interest() Modified unit test and golden test for zero bonds.