pricingWithZspread {bondAnalyst} | R Documentation |
Calculates Bond Price using the given value of a Z-Spread and spot rates taken from the spots curve.
pricingWithZspread(cpns, spots, t, mv, n, zSprd)
cpns |
A vector. |
spots |
A vector. |
t |
A vector. |
mv |
A number. |
n |
A number. |
zSprd |
A number. |
According to information provided by Adams and Smith (2019), the method pricingWithZspread()
is developed to compute Bond Price using the given value of a Z-Spread and spot rates taken from the spots curve. Here, cpns
is vector of Coupon Payments, spots
is a vector of spot rates taken from the spots curve, t
is a vector of number of years ranging from 1 to any specified number of years under consideration, mv
is maturity value of the bond, n
is number of years for which spots are available, and zSprd
is given value of a Z-spread.
Input values to six arguments cpns
, spots
,t
,mv
, n
and zSprd
.
MaheshP Kumar, maheshparamjitkumar@gmail.com
Adams,J.F. & Smith,D.J.(2019). Introduction to fixed-income valuation. In CFA Program Curriculum 2020 Level I Volumes 1-6. (Vol. 5, pp. 107-151). Wiley Professional Development (P&T). ISBN 9781119593577, https://bookshelf.vitalsource.com/books/9781119593577
pricingWithZspread(cpns=c(6,6),spots=c(0.0210,0.03635),t=c(1,2),mv=100,n=2,zSprd=0.023422)
pricingWithZspread(cpns=c(5,5,5),spots=c(0.0486,0.0495,0.0565),t=c(1,2,3),mv=100,n=3,zSprd=0.0234)
pricingWithZspread(cpns=c(rep(5,3)),spots=c(0.0486,0.0495,0.0565),t=c(1:3),mv=100,n=3,zSprd=0.0234)
pricingWithZspread(c(rep(5,3)),c(0.0486,0.0495,0.0565), c(1:3),100,3, zSprd=0.0234)