2. A bond price is the present value of all future cash flows (coupon interest every year and par value at time to maturity) as shown in Ch 7 course material. That is,
where
Par: par value of the bond
c_rate: annual coupon rate
t: time to maturity
y: bond yield
A function to calculate a bond price is presented on p. 5 in Ch 7 course material. As you can see, the function exactly illustrates the equation above.
1) Suppose you have to find coupon rate when you know all other variables, such as the bond price, par value, time to maturity, and yield. To find coupon rate instead of bond price, you can use the following formula (if you solve the equation above for c_rate, you can easily obtain this formula.).
Therefore, if you invest in a bond that has $1,157.449 of current bond price, $1,200 of par value, 4 years to maturity, and 5% of yield, you can calculate coupon rate as follows:
# Create time t
t <- seq(1, 4, 1)
# Create present value factor
pv_factor <- 1 / (1 + 0.05)^t
# Current bond price
bond_value <- 1157.449
# Par value
c_rate <- (1157.449 – 1200 / (1+0.05)^4) / (1200*sum(pv_factor))
c_rate
[1] 0.0400001
a) Referring to the codes above, create your own function to calculate coupon rate. That is, you have to complete the body of the following function (bond_value: current bond price, par: par value, ttm: time to maturity, and y: yield).
c_rate <- function (bond_value, par, ttm, y) {
COMPLETE THIS PART
}
b) Using your own function created in part a), calculate coupon rate of the bond with
bond_value = $1,172.61
par = $1,000
ttm = 10 years
y = 6%
2) Suppose you have to find par value when you know all other variables, such as the bond price, coupon rate, time to maturity, and yield. To find par value instead of bond price, you can use the following formula (if you solve the equation above for Par, you can easily obtain this formula.).
Therefore, if you invest in a bond that has $1,070.919 of current bond price, 7% of annual coupon rate, 4 years to maturity, and 5% of yield, you can calculate par value as follows:
# Create time t
t <- seq(1, 4, 1)
# Create present value factor
pv_factor <- 1 / (1 + 0.05)^t
# Coupon rate times pv_factor
c_pv_factor <- 0.07 * pv_factor
# Current bond price
bond_value <- 1070.919
# Par value
par <- bond_value / (sum(c_pv_factor) + (1 / (1+0.05)^4))
par
[1] 1000
a) Referring to the codes above, create your own function to calculate par value. That is, you have to complete the body of the following function (bond_value: current bond price, c_rate: coupon rate, ttm: time to maturity, and y: yield).
par <- function (bond_value, c_rate, ttm, y) {
COMPLETE THIS PART
}
b) Using your own function created in part a), calculate par value of the bond with
bond_value = $1,319.8278
c_rate = 5%
ttm = 13 years
y = 4%
Students succeed in their courses by connecting and communicating with an expert until they receive help on their questions
Consult our trusted tutors.