Credit spread
Credit risk is one of the major problems for financial institutions. The major cause for this is credit quality, and credit spread values help to understand credit risk depending upon the credit quality. Credit spread is an important concept in institutional trading as credit spread depends upon the quality or rating of bonds. It is the difference in bond yield of two bonds with similar maturity but with different bond ratings. We are going to use the CreditMetrics
package for this, which can be installed and imported to the R workspace using the following two commands:
> install.packages('CreditMetrics') > library('CreditMetrics')
Credit spread is calculated using cm.cs()
, which has just two parameters. The first parameter is the one-year migration matrix for some institution or government which issues credit and the second parameter is loss given default (LGD), which means maximum loss if the obligor of credit defaults. Normally, credit with rating AAA
is on the top...