| Products & Services | Industries | Academia | Support | User Community | Company |
| Download Product Updates | | | Get Pricing | | | Trial Software |
| Documentation → Financial Toolbox |
| Contents | Index |
| Learn more about Financial Toolbox |
[ModDuration, YearDuration, PerDuration] = bnddury(Yield,
CouponRate,
Settle, Maturity)
[ModDuration, YearDuration, PerDuration] = bnddury(Yield,
CouponRate,
Settle, Maturity, Period, Basis, EndMonthRule,
IssueDate,
FirstCouponDate, LastCouponDate, StartDate,
Face)
[ModDuration, YearDuration, PerDuration] = bnddury(Yield,
CouponRate,
Settle, Maturity, 'ParameterName',
'ParameterValue ...)
[ModDuration, YearDuration, PerDuration] = bnddury(Yield, CouponRate, Settle, Maturity) computes the Macaulay and modified duration of NUMBONDS fixed income securities given yield to maturity for each bond.
[ModDuration, YearDuration, PerDuration] = bnddury(Yield, CouponRate, Settle, Maturity, Period, Basis, EndMonthRule, IssueDate, FirstCouponDate, LastCouponDate, StartDate, Face)
[ModDuration, YearDuration, PerDuration] = bnddury(Yield, CouponRate, Settle, Maturity, 'ParameterName','ParameterValue ...) accepts optional inputs as one or more comma-separated parameter/value pairs. 'ParameterName' is the name of the parameter inside single quotes. ParameterValue is the value corresponding to 'ParameterName'. Specify parameter/value pairs in any order. Names are case-insensitive.
Yield |
Yield to maturity on a semiannual basis. |
CouponRate |
Decimal number indicating the annual percentage rate used to determine the coupons payable on a bond. |
Settle |
Settlement date. A vector of serial date numbers or date strings. Settle must be earlier than or equal to Maturity. |
Maturity |
Maturity date. A vector of serial date numbers or date strings. |
Enter the following inputs using an ordered syntax or as parameter/value pairs. You cannot mix ordered syntax with parameter/value pairs.
Period |
Coupons per year of the bond. A vector of integers. Values are 0, 1, 2, 3, 4, 6, and 12. Default: 2 |
Basis |
Day-count basis of the instrument. A vector of integers.
Default: 0 |
EndMonthRule |
End-of-month rule. A vector. This rule applies only when Maturity is an end-of-month date for a month having 30 or fewer days. 0 = ignore rule, meaning that a bond coupon payment date is always the same numerical day of the month. 1 = set rule on, meaning that a bond coupon payment date is always the last actual day of the month. Default: 1 |
IssueDate |
Issue date for a bond. |
FirstCouponDate |
Irregular or normal first coupon date. |
LastCouponDate |
Irregular or normal last coupon date. |
StartDate |
Date when a bond actually starts (the date from which a bond cash flow is considered). To make an instrument forward-starting, specify this date as a future date. If you do not specify StartDate, the effective start date is the Settle date. |
Face |
(Optional) Face or par value. Default: 100 |
Enter the following inputs only as parameter/value pairs.
CompoundingFrequency |
Compounding frequency for yield calculation. By default, SIA bases (0-7) and BUS/252 use a semiannual compounding convention and ISMA bases (8-12) use an annual compounding convention. |
DiscountBasis |
Basis used to compute the discount factors for computing the yield. The default behavior is for SIA bases to use the actual/actual day count to compute discount factors. If you use ISMA day counts and BUS/252, the specified bases are used. |
ModDuration |
NUMBONDS-by-1 vector for the modified duration in years, reported on a semiannual bond basis (in accordance with SIA convention). |
YearDuration |
NUMBONDS-by-1 vector for the Macaulay duration in years. |
PerDuration |
NUMBONDS-by-1 vector for the periodic Macaulay duration reported on a semiannual bond basis (in accordance with SIA convention). |
bnddurp determines the duration for a bond whether the first or last coupon periods in the coupon structure are short or long (that is, whether the coupon structure is synchronized to maturity). This function also determines the Macaulay and modified duration for a zero coupon bond.
All specified arguments must be number of bonds (NUMBONDS)-by-1 or 1-by-NUMBONDS conforming vectors or scalar arguments. Use an empty matrix ([]) as a placeholder for an optional argument. Fill in unspecified entries input vectors with NaNs. Dates can be serial date numbers or date strings.
Find the duration of a bond at three different yield values:
Yield = [0.04; 0.055; 0.06]; CouponRate = 0.055; Settle = '02-Aug-1999'; Maturity = '15-Jun-2004'; Period = 2; Basis = 0; [ModDuration,YearDuration,PerDuration]=bnddury(Yield,... CouponRate, Settle, Maturity, Period, Basis)
This returns:
ModDuration =
4.2444
4.1924
4.1751
YearDuration =
4.3292
4.3077
4.3004
PerDuration =
8.6585
8.6154
8.6007Krgin, Dragomir, Handbook of Global Fixed Income Calculations, John Wiley & Sons, 2002.
Mayle, Jan, "Standard Securities Calculations Methods: Fixed Income Securities Formulas for Analytic Measures", SIA, Vol 2, Jan 1994.
Stigum, Marcia, and Franklin Robinson, Money Market and Bond Calculations, McGraw-Hill, 1996.
bndconvp | bndconvy | bnddurp | bndkrdur
![]() | bnddurp | bndkrdur | ![]() |
View demos and recorded presentations led by industry experts.
Now On Demand
Network with industry peers and learn the latest applications of the leading software product for computational finance.
| © 1984-2009- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |