OpenBI Docs Buy

MDURATION

A bond's modified duration.

Group: Financial. Compatible with DAX.

Syntax

MDURATION ( <settlement>, <maturity>, <coupon>, <yld>, <frequency> [, <basis>] )
ParameterTypeDescription
settlementDateThe day the buyer takes the security over; later than its issue.
maturityDateThe day the security ends and its face value is repaid.
couponNumberThe coupon rate a year, as a decimal.
yldNumberThe yield a year the buyer earns, as a decimal.
frequencyWhole numberCoupons a year: 1 for yearly, 2 for half-yearly, 4 for quarterly.
basisWhole number
optional
The day count, by number: US 30/360 (0, when left out), actual/actual (1), actual/360 (2), actual/365 (3) or European 30/360 (4).

Returns

Number. The modified duration: the Macaulay duration divided by 1 + yld / frequency.

Remarks

  • It tells how much the price moves with the yield: a modified duration of 5.7 means a rise of 0.01 in the yield (one percentage point) lowers the price by about 5.7 %.
  • A coupon or yield below 0, or settlement on or after maturity, is an error.
  • The dates are taken as whole days. frequency and basis are rounded to whole numbers first; a frequency other than 1, 2 or 4, or a basis outside 0 to 4, is an error.

Examples

An eight-year bond

8 % half-yearly coupons at a 9 % yield.

EVALUATE
ROW (
    "DURATION", DURATION ( DATE ( 2008, 1, 1 ), DATE ( 2016, 1, 1 ), 0.08, 0.09, 2, 1 ),
    "MDURATION", MDURATION ( DATE ( 2008, 1, 1 ), DATE ( 2016, 1, 1 ), 0.08, 0.09, 2, 1 )
)
DURATIONMDURATION
5.993774955545195.73566981391884

DURATION, PRICE, YIELD.

Last updated · OpenBI Studio 0.3.74