Yield to maturity (YTM) refers to the approximate rate of return that the bond holders earn by holding bonds until maturity. In other word, Yield to Maturity is a discounting rate that makes the present value of payments received from the bonds equal to it's price. It can be calculated by using the following formulae:
YTH = [I + (M - Po)/n]/[(2M + P)/3]
Or
YTH = [I + (M - Po)/n]/[(M + P)/2]