Cernarus

Modified Duration Calculator

This tool calculates Macaulay and Modified duration for standard fixed-rate bonds and estimates Effective duration using a price-shift numerical method. Duration measures a bond's sensitivity to small, parallel changes in yield and is used for interest-rate risk management.

Two modes are provided: a formula-based Macaulay→Modified route (requires yield-to-maturity and bond specs) and a price-shift effective-duration route (useful for bonds with embedded options or when cash-flow sensitivity is unknown). The calculator reports intermediate values (model clean price, Macaulay duration in years) to support validation and audit.

Updated Nov 3, 2025

Calculates Macaulay duration from a fixed schedule of level coupon payments using yield-to-maturity and converts to Modified duration using the chosen compounding frequency.

Inputs

Advanced inputs

Bond specifications

Yield inputs (used by Macaulay/Modified method)

Price-shift inputs (used by Effective Duration)

Results

Updates as you type

Model clean price

-$9,035.00

Macaulay duration (years)

Modified duration

OutputValueUnit
Model clean price-$9,035.00currency
Macaulay duration (years)years
Modified durationyears
Primary result-$9,035.00

Visualization

Methodology

Macaulay duration is the weighted average time to receive the bond's cash flows where weights are present-value fractions. Modified duration adjusts Macaulay by the periodic yield to estimate percent price change per unit yield change under small, parallel shifts.

Effective duration is computed numerically by observing model or market price changes to small yield perturbations and is preferred when cash flows change with yield (for callable, convertible, or prepayable instruments).

Numerical and rounding behavior follows IEEE 754 floating point conventions for predictable results. Quality control and traceability recommendations reference ISO and NIST guidance on measurement uncertainty and software quality management.

Worked examples

Example 1 (standard): 5-year bond, 5% annual coupon, semiannual payments, face 1000, YTM 4.5% → compute model price, Macaulay and Modified durations. Use Macaulay→Modified mode.

Example 2 (embedded option): For a callable bond, run a valuation model to obtain P0, P(+Δy), and P(-Δy) then use the price-shift mode to estimate effective duration.

Key takeaways

Use the Macaulay→Modified mode for standard fixed-cash-flow bonds when you know the yield. Use the price-shift mode to estimate effective duration for instruments with yield-dependent cash flows.

Document inputs (day-count, Δy, price type), validate with test vectors, and be aware of linear approximation limits. Follow IEEE numeric practices and ISO/NIST recommendations for QA and traceability.

Further resources

External guidance

Expert Q&A

When should I use Modified duration versus Effective duration?

Use Modified duration for plain-vanilla fixed-rate bonds with fixed cash flows. Use Effective duration for bonds whose cash flows change with yield (callable, puttable, convertible, mortgage-backed).

What size of Δy should I use for price-shift effective duration?

Choose a small absolute shift (for example 1–10 basis points = 0.0001–0.001) so linear approximation holds but large enough to avoid numerical noise. Report Δy when saving results.

Does this calculator handle day-count conventions and accrued interest?

This tool uses simple period counts (payments per year) for duration formulas. Accrued interest and detailed day-count adjustments are informational; include those adjustments externally when using market clean/dirty prices.

How accurate are the results and what are the limitations?

Results assume level periodic coupons and parallel yield shifts. Modified duration is a linear approximation and ignores convexity; effective duration accounts for nonlinearity if proper shifted prices are provided. Numerical rounding follows IEEE floating-point; document test vectors and error tolerances when using results for regulatory reporting.

Is there guidance for testing and quality control?

Validate the implementation with known analytic test cases, check convergence for numerical solvers, record input snapshots, and follow ISO 9001 quality practices and NIST measurement uncertainty guidance for traceability.

Sources & citations