YTD measures the annual return an investor would receive if he or she held a particular bond until maturity.
It is also known as redemption yield. As the name suggests, if an investment is held till its maturity date, the rate of return that it will generate will be Yield to Maturity.
It is the speculative rate of return or interest rate of fixed-rate security, such as a bond.
let's assume you own a Company XYZ bond with a $1,000 par value and a 5% coupon that matures in three years. If this Company XYZ bond is selling for $980 today on the market, using the formula above we can calculate that the YTM is 2.87%.
YTM = (C + (F - P) / n) / ((F + P) / 2)