logic.codes

Bond Yield to Maturity Calculator

What yield to maturity does this bond price imply, and what is its duration?

Single calculationv1.0.0Verified 2026-11-01Runs in your browser

Spec sheet

street_ytm · v1.0.0
Method

Street-convention yield (compounding at coupon frequency), solved by bisection

  1. 01Dirty = Σ c·v^(k+w) + R·v^(N−1+w), v = 1/(1 + y/f)
  2. 02w = fraction of the current period remaining (day count)
  3. 03Clean = Dirty − accrued interest
  4. 04Modified duration = Macaulay ÷ (1 + y/f)
Limits — read before relying on it
  • Fixed coupons, bullet redemption at par; no calls, sinking funds or floating rates.
  • No business-day adjustment of coupon dates; end-of-month rules follow the maturity date's day.
  • A model yield, not a market quote.
Sources
  • ISDA 2006 Definitions §4.16 — day count fractions (as implemented in QuantLib)standard

Related