Skip to main content

Portfolio optimization of credit risky bonds: a semi-Markov process approach


This article presents a semi-Markov process based approach to optimally select a portfolio consisting of credit risky bonds. The criteria to optimize the credit portfolio is based on l-norm risk measure and the proposed optimization model is formulated as a linear programming problem. The input parameters to the optimization model are rate of returns of bonds which are obtained using credit ratings assuming that credit ratings of bonds follow a semi-Markov process. Modeling credit ratings by semi-Markov processes has several advantages over Markov chain models, i.e., it addresses the ageing effect present in the credit rating dynamics. The transition probability matrices generated by semi-Markov process and initial credit ratings are used to generate rate of returns of bonds. The empirical performance of the proposed model is analyzed using the real data. Further, comparison of the proposed approach with the Markov chain approach is performed by obtaining the efficient frontiers for the two models.


The problem of credit risk, which consists of finding the likelihood of default of an obligor going into debt, is one of the most important problems in financial world. The credit risk, also known as default risk, is the risk of lender that borrower may not be able to meet its debt obligations. Credit risk analysis consists of finding the likelihood of default of an obligor going into debt. Credit risk models are basically divided into reduced-form models and firm value models (also known as structural models). Firm value models consider the model in Merton (1974) as the base model, which gives a mechanism of default in terms of the relation between liabilities and assets at maturity time T. On the other hand, reduced-form models do not specify the actual mechanism of default but model it as a non-negative random variable with distribution depending on the economic co-variables, interested readers can refer Duffie and Singleton (2012). There are many parameters associated with bond issuer or bond itself, which quantify the credit risk associated with it. Credit rating is one of the important parameters. Credit rating of a credit risky bond, assigned by a company, is an evaluation of its likelihood of default and ability to pay back the loan. Better the credit rating of a bond, safer it is. Banks and the firms that issue bonds are most concerned to quantify the default risk. International organizations like Standard & Poor’s assign ratings to the companies that issue bonds in order to evaluate the credit risk. A credit rating is given to each company that issues a bond, specifying its capacity to repay the debt. Clearly, a higher interest rate is expected from a firm whose rating is lower. Credit ratings have become important since they are used as an input in many models for calculating economic capital for banks. Therefore, estimating the transition matrices of credit ratings is at the core of risk management and has applications in pricing derivatives and credit portfolio optimization.

Models for credit quality based on ratings are also frequently used in the pricing and risk management literature, see for example Jarrow et al. (1997); Kijima and Komoribayashi (1998); Akutsu et al. (2003). In 1997, Jarrow et al. (1997) applied for the first time Markov processes to capture the time evolution of credit ratings. These models are called “migration models". One of the drawbacks of this model is that it gives, in small time interval, zero probability of default to bonds with high credit ratings. Other papers (Hu et al. 2002; Nickell et al. 2000; Baillo and Fernandez 2007; Grimshaw and Alexander 2011)) followed the same approach to generate the transition matrix. More recent contributions include the quantification of the impact of business cycles on the dynamics of credit ratings and corresponding computation of conditional migration matrices (Boreiko et al. 2018), the proposal of parsimonious higher order Markov chains models able to reproduce downgrade rating momentum effects (Baena-Mirabete and Puig 2018) and the modeling of credit default data with intensity-based model stemmed from hidden Markov chains (Yu et al. 2017; Yu et al. 2019). In 2017, Dharmaraja et al. (2017) proposed a Markov chain model with catastrophe to determine the mean time of default of a risky asset. Centanni et al. (2017) modelled the dynamics of defaults for a dynamic set of firms in a given time period under the Markovian assumption. They assumed that there are some observable variables such as the total number of defaults, the total number of firms operating in the market at time t and some unobservable variables such as the number of firms alive or defaulted in each class at time t. Then, they using particle filtering techniques they obtained an approximation of the distribution of unobserved variables. Later, Tardelli (2018) extended this idea to find the probabilistic prediction of the actual partition of the population, and of the conditional distribution of the distance to defaults. In other direction on empirical analysis, Kou et al. (2014) studied the effectiveness of multiple criteria decision making methods in evaluating clustering algorithms by performing experiments on real-life credit risk and bankruptcy risk data sets.

In the papers by Nickell et al. (2000); Kavvathas (2001); Lando and Skødeberg (2002), appropriateness of Markov process for the description of accurate rating dynamics was addressed. Carty and Fons (1994); Nickell et al. (2000) proved that the current rating of a company depends not only on its last rating but on all the previous ones, the effect called rating momentum. Thus, the evolution of credit rating dynamics is non-Markov. Carty and Fons (1994); Duffie and Singleton (2012), showed that a complete information of the time spent inside the states is of major interest in the credit risk problem. The credit migration probability depends on the time spent by a company in a particular rating. In a continuous-time homogeneous Markov chain, durations in states follow an exponential distribution. An exponential distribution has a constant hazard function. But for credit rating dynamics, the hazard function is not constant. Hence, Markov model for credit rating is not appropriate (Frydman and Schuermann 2008). The other issue is time dependence. It means that in general, transition probabilities tends to change with the state of the economy, being low during periods of economic expansion and high during recession. Rating evaluation at two different time points is different (Nickell et al. 2000) and hence the process describing the evolution of rating dynamics is time non-homogeneous.

The literature proposing models that addresses the non-Markov behavior of credit rating dynamics is of recent origin. Korolkiewicz and Elliott (2008) proposed a hidden Markov model assuming that the Markov chain governing the true credit quality evolution is hidden in noisy or incomplete observations about credit ratings. In the paper by D’Amico et al. (2005), they have considered the credit risk problem as a reliability problem. They applied time-homogeneous semi-Markov processes (SMP) to solve the first issue. The second issue has been solved by extending the state space by the same authors (D’Amico et al. 2016) and many further developments have been made in their model (D’Amico et al. 2011; D’Amico et al. 2010; D’Amico et al. 2012). In 2017, Pasricha et al. (2017) proposed a credit rating model based on a Markov regenerative process which is a generalization of semi-Markov process model.

By optimization of portfolio consisting of credit risky bonds, we mean to find the optimal allocation of the wealth to the risky bonds in the portfolio such that the overall credit risk is minimum. In order to formulate a optimization problem, we need to define the risk measure to be used. For example, in equity portfolio optimization, the pioneering work by Markowvitz (1952) considers the variance of portfolio return as the risk measure. Konno and Yamazaki (1991) introduced mean absolute deviation as measure of risk and Young (1998) considered lnorm as a risk measure. In credit portfolio optimization, value at risk was considered to quantify the portfolio credit risk in Morgan (1997). Later, Andersson et al. (2001) proposed a credit portfolio optimization model based on conditional value at risk (CVaR). Further Kalkbrener et al. (2007) considered risk measures VaR and CVaR (referred therein as Expected shortfall) for credit risk optimization formulation with importance sampling technique for calculation of risk measures. Their formulation overcomes the numerical problems associated with calculation of CVaR allocation in credit portfolio models. The other models proposed in the literature considered l1 norm i.e., mean absolute deviation and l2 norm i.e., variance as a measure of risk. In (2017), Singh and Dharmaraja (2017) proposed a l based credit portfolio optimization using credit rating dynamics modeled by a Markov chain. In 2015, Ma et al. (2015) proposed a model based on extreme value theory to evaluate the default risk of bond portfolios.

On similar lines to Singh and Dharmaraja (2017), this article considers a l norm i.e., min-max absolute deviation credit portfolio optimization model. However, due to the limitations of the Markov chains to model the credit rating dynamics, we assume that the credit rating dynamics of the risky bonds are assumed to follow a semi-Markov process and propose new risk premium adjustments for the pricing purposes. The transition probabilities of the rating migration is obtained using the historical data. Based on the transition probabilities, future credit ratings are obtained and hence following Jarrow et al. (1997), the price paths of credit risky bonds are obtained. These generated paths of returns of bonds are input parameters to the optimization model. Extensive numerical illustrations are given to show the applicability of the proposed model and is compared with Markov chain model proposed by Singh and Dharmaraja (2017). This article uses semi-Markov process to obtain the transition probabilities of the rating migration, however, one can consider the models by Centanni et al. (2017); Tardelli (2018) to obtain the dynamics of credit quality of firms and generate the path of bond returns.

The rest of the paper is organized as follows. “The proposed framework” section introduces the min-max absolute deviation model followed by the semi-Markov credit rating model. “Proposed methodology” section proposed the algorithm to generate the future credit rating scenarios credit rating followed by the methodology to solve the portfolio optimization model based on the generated ratings. Numerical illustrations are given in “Empirical analysis” section, and “Conclusions and future work” section concludes the paper with future work.

The proposed framework

In the first subsection, we give a brief review of the l norm risk measure based portfolio optimization model. In the next subsection, a semi-Markov credit rating model proposed in D’Amico et al. (2005) is presented. In the reminder of the paper, we shall be using the following notations:

\(\begin {array}{ll} N & \textrm {Number\; of\; bonds\; in\; the \;portfolio}\\ x_{n} & \textrm {dollar \;amount\;spent\;on}\,\, n\textrm {th \;bond\;in\; the\; portfolio}\\ T & \textrm {length \;of\; time \;horizon} \\ t& \textrm {each \;period\; over \; the \; time \;horizon}~~t=1,2,\ldots T \\ r_{j} & \textrm {the\; expected \;return}~E(R_{j})~\textrm { of\; asset }~~j\\ r_{jt} & \textrm {the \;observed \;return \;of \;asset}~j~\textrm {during \;the \;period}~~t\\ C & \textrm {the\; total\; portfolio \;expenditure}\\ d & \textrm {user\; defined \;value\; minimum \; rate \;of \;return \;required \;by \;investor.}\\ \end {array}\)

Note that here we assume that the bonds are zero coupon bonds.

l or Min-Max absolute deviation model

Young (1998) proposed a l-norm risk measure based portfolio optimization model of equities. Following this approach, Cai et al. (2000) considered maximum of absolute deviation of individual asset’s return as measure of risk, that is l-norm risk measure. In 2017, Singh and Dharmaraja (2017) proposed a l based credit portfolio optimization. In this section, we present the mathematical formulation of minimizing the maximum absolute deviation as follows:

$$\begin{array}{*{20}l} & \min \max_{t=1,2,\ldots,T} \begin{aligned} |\sum_{j=1}^{N}(r_{jt}-r_{j})x_{j}| \notag \\ \end{aligned} \\ & \text{subject to}\notag \\ &\sum_{j=1}^{N}r_{j}x_{j} \geq dC \notag\\ & \sum_{j=1}^{N}x_{j}=C \notag \\ & x_{j}\geq 0,\;\;j=1,2,\ldots,N\notag \end{array} $$

The objective here is to minimize the maximum of the absolute deviation of portfolio return. In other words, instead of minimizing mean of the absolute deviations, we propose to minimize the worst possible performance of the portfolio. This is more conservative portfolio selection rule and is suitable for risk-averse investors. Further, the first constraint restrict the mean portfolio to be greater than a threshold percentage d of the total budget C, given by the second constraint. Finally, the last constraint indicates the restriction on short selling. This original problem can be reformulated into a linear programming problem using auxiliary variable yt as follows:

Let \(y_{t}=|\sum _{j=1}^{N}(r_{jt}-r_{j})x_{j}|\) for all t=1,2,…,T. This implies that for all t=1,2,…,T, we have

$$\begin{array}{@{}rcl@{}} y_{t}-\sum_{j=1}^{N}(r_{jt}-r_{j})x_{j}&\geq& 0\\ y_{t}+\sum_{j=1}^{N}(r_{jt}-r_{j})x_{j}&\geq& 0 \end{array} $$

Let us assume that Y= maxt=1,2,…,Tyt. This implies that for all t=1,2,…,T, we have

$$y_{t}\leq Y$$

Using these transformations we get the following linear programming problem:

$$\begin{array}{*{20}l} (P)_{0} \hspace*{1cm}& \min \begin{aligned} Y \notag \\ \end{aligned} \\ & \text{subject to}\notag \\ & y_{t}\leq Y \;\;t=1,2,\ldots,T\notag\\ &y_{t}-\sum_{j=1}^{N}(r_{jt}-r_{j})x_{j}\geq 0\;\;t=1,2,\ldots,T\notag\\ &y_{t}+\sum_{j=1}^{N}(r_{jt}-r_{j})x_{j}\geq 0\;\;t=1,2,\ldots,T\notag\\ &\sum_{j=1}^{N}r_{j}x_{j} \geq dC \notag\\ & \sum_{j=1}^{N}x_{j}=C \notag \\ & x_{j}\geq 0,\;\;j=1,2,\ldots,N\notag \end{array} $$

Semi-Markov credit rating model

The level of credit rating changes from time to time because of random credit risks and thus need to be modeled by an appropriate stochastic process. Jarrow et al. (1997) considered the credit rating process {X(t),t≥0} to be a continuous-time Markov chain with state space Ω={1,2,3,…,8} where 1 represent the highest rating AAA and 8 represent the default D. But in literature, several empirical evidences suggest that Markov process is not appropriate for credit rating process. There are three main issues on the suitability of the Markov processes for the credit rating evolution namely rating evaluation are dependent on time, downward rating momentum and time duration inside a rating. D’Amico et al. (2005) proposed a semi-Markov model to overcome these issues. In order to develop the proposed model, a brief overview of discrete time-homogeneous semi-Markov credit rating model proposed by D’Amico et al. (2005) is given.

A sequence of the random variables {(Xn,Tn),n=0,1,…} is called a Markov renewal sequence if

  1. 1

    T0=0, Tn+1Tn; XnΩ={0,1,2,…},Tn≥0

  2. 2



    =P{Xn+1=j,Tn+1TntXn=i} (Markov property)

    =P{X1=j,T1T0tX0=i} (time homogenity)

The kernel Q(t)=[Qi,j(t)] associated with the process is defined by

$$Q_{ij}(t)=P\{X_{n+1}=j,T_{n+1}-T_{n} \leq t |X_{n}=i\},~~i,j\in\Omega,~t\geq0.$$

and it follows that

$$p_{ij}={\lim}_{t\rightarrow \infty} Q_{ij}(t),~~ i,j\in \Omega.$$

where P=[pij]i,jΩ is the one-step transition probability matrix of the embedded discrete time Markov chain with state space Ω.

The probability that the process will leave state i in time t is given as,

$$H_{i}(t)=P(T_{n+1}-T_{n}\leq t\mid X_{n}=i)~~\forall~n, i\in \Omega, t\geq 0$$

It can be observed that


Next, consider the distribution function of the waiting time in each state i, given that the next state is known

$$G_{ij}(t)=P\{T_{n+1}-T_{n}\leq t |X_{n}=i,X_{n+1}=i\},~~i,j\in\Omega,~t\geq0.$$

These probabilities can be obtained as follows

$$G_{ij}(t)= \left\{ \begin{array}{ccc} \frac{Q_{ij}(t)}{p_{ij}} &\, \text{if} \,& p_{ij}\neq 0 \\ 1 &\, \text{if} \,& p_{ij}=0 \\ \end{array} \right..$$

The main difference between a continuous-time Markov chain and an SMP is the distribution functions Gij(t). In a Markov environment this distribution function has to be cumulative distribution function a negative exponential distribution. On the other hand, in the semi-Markov case the distribution functions Gij(t) can be cumulative distribution of any general distribution. Thus accounting for the effect of duration inside a rating class.

Now, a time-homogeneous semi-Markov process { Z(t),t≥0}, which represents, for each waiting time, the state occupied by the process is defined as

$$Z(t)=X_{N(t)}~\text{where}~N(t)=\max\{n\in\mathbb{N}:T_{n}\leq t\}.$$

The transition probabilities for { Z(t),t≥0} are defined by

$$\phi_{ij}(t)=P\{Z(t)=j\mid Z(0)=i\},i,j \in \Omega,~t\geq 0.$$

They can be obtained by solving the Markov renewal equation (Kulkarni 2016)

$$\phi_{ij}(t)=\delta_{ij}(1-H_{i}(t))+\sum_{\gamma \in \Omega} \int_{0}^{t} \phi_{\gamma j}(t-y){dQ}_{i\gamma}(y),~i,j\in \Omega$$

where δij represents Kronecker delta. This equation can be solved numerically using discretization to numerically evaluate the integrals. Let h>0 be the step size of discretization, then we have the countable linear system given by

$$\phi_{ij}^{h}(kh)=\delta_{ij}(1-H_{i}(kh))+\sum_{\gamma \in \Omega}\sum_{\tau=1}^{k} q_{i\gamma}(\tau h) \phi_{\gamma j}^{h}((k-\tau)h),~~k=0,1,\ldots$$


$$q_{ij}(kh)= \left\{ \begin{array}{ccc} Q_{ij}(kh)-Q_{ij}((k-1)h) & if & k>0 \\ 0 & if & k=0.\\ \end{array} \right..$$

In the credit risk environment, the first part of above equation can be interpreted as the probability of the firm to remain in rating i from time 0 to t given that the rating organization gave a new rating evaluation at time 0. In the second part of above equation, ϕγj(tτ)qiγ(τ) represents the probability that firm will get a rating γ in time τ given that starting at time 0 from state i and then firm will migrate to rating j in remaining time (tτ) following one of the possible paths. ϕi,j(t) are the actual transition probabilities of the observed discrete time-homogeneous semi-Markov process.

Proposed risk premium adjustments

For the pricing purposes, we need to define the probabilities under risk neutral measure. In this section we consider a change of measure that is compatible with the general theory developed by Vasileiou and Vassiliou (2006):

$$ \tilde{Q}_{ij}(t)=\ell_{i}(t)Q_{ij}(t)~~~\forall i\neq j,~t\geq 0 $$

where \(\tilde {Q}_{ij}(t)\) is the kernel in the risk neutral world and i(t) are the risk premium adjustments. Since Q(t) is only asymptotically stochastic, we have the following constraint

$$ {\lim}_{t\rightarrow \infty} \sum_{j\in \Omega}\tilde{Q}_{ij}(t)=\sum_{j\in \Omega}P_{ij}=1. $$

This implies that

$$\begin{array}{@{}rcl@{}} {\lim}_{t\rightarrow \infty} \tilde{Q}_{ii}(t)&=&P_{ii}\\ &=&1-{\lim}_{t\rightarrow \infty} \sum_{j\neq i}\tilde{Q}_{ij}(t)\\ &=&1-{\lim}_{t\rightarrow \infty} \sum_{j\neq i}\ell_{i}(t)Q_{ij}(t)\\ &=&1-\ell_{i}^{*}\sum_{j\neq i}P_{ij}\\ &=&1-\ell_{i}^{*}(1-P_{ii}) \end{array} $$

where \({\lim }_{t\rightarrow \infty }\ell _{i}(t)=\ell _{i}^{*}\). Hence, we proposed the following change of measure for t≥0,

$$\tilde{Q}_{ij}(t)=\left\{ \begin{array}{ccc} \ell_{i}(t)Q_{ij}(t), & if & i\neq j \\ 1-\ell_{i}(t)(1-Q_{ii}(t)) & if & i=j \\ \end{array} \right. $$

with \({\lim }_{t\rightarrow \infty }\ell _{i}(t)=\ell _{i}^{*}\). Since we need to obtain \(\tilde {Q}(\cdot)\) as a semi-Markov kernel, then some restrictions should be considered for the function (t) other than \({\lim }_{t\rightarrow \infty }\ell _{i}(t)=\ell _{i}^{*}\). More precisely,

  1. 1

    \(\tilde {Q}_{ij}(0)=0~~\forall i,j\in \Omega \). This means that

    $$\begin{array}{@{}rcl@{}} \tilde{Q}_{ij}(0)&=&\ell_{i}(0)Q_{ij}(0)=\ell_{i}(0).0=0~~~ \forall i\neq j. \end{array} $$


    $$\begin{array}{@{}rcl@{}} \tilde{Q}_{ii}(0)&=&1-\ell_{i}(0)(1-Q_{ii}(0))=1-\ell_{i}(0)(1-0) \end{array} $$

    which implies i(0)=1.

  2. 2

    Qij(t) is an increasing function of t, i.e.,

    $$\begin{array}{@{}rcl@{}} \tilde{Q}_{ij}(t+h)\geq\tilde{Q}_{ij}(t)~\forall~~h\geq 0~~~\forall i\neq j.\\ \end{array} $$

    This means that

    $$\begin{array}{@{}rcl@{}} \ell_{i}(t+h)Q_{ij}(t+h)&\geq&\ell_{i}(t)Q_{ij}(t)\\ \Rightarrow\frac{\ell_{i}(t+h)}{\ell_{i}(t)}&\geq& \frac{Q_{ij}(t+h)}{Q_{ij}(t)}~~\forall~h\geq 0~~\forall i\neq j.\\ \end{array} $$

    Similarly, for i=j, we have

    $$\begin{array}{@{}rcl@{}} \tilde{Q}_{ii}(t+h)\geq\tilde{Q}_{ii}(t)~~~\forall h\geq 0. \end{array} $$

    This means that

    $$\begin{array}{@{}rcl@{}} 1-\ell_{i}(t+h)(1-Q_{ii}(t+h))&\geq&1-\ell_{i}(t)(1-Q_{ii}(t))\\ \Rightarrow\ell_{i}(t+h)(1-Q_{ii}(t+h))&\leq& \ell_{i}(t)(1-Q_{ii}(t))\\ \Rightarrow\frac{\ell_{i}(t+h)}{\ell_{i}(t)}&\leq& \frac{1-Q_{ii}(t)}{1-Q_{ii}(t+h)}~~~\forall h\geq 0. \end{array} $$

Summarizing, we have that the function i(t) should satisfy the following conditions

  1. 1

    i(0)=1 iΩ.

  2. 2

    \({\lim }_{t\rightarrow \infty } \ell _{i}(t)=\ell _{i}^{*} \in \mathbb {R}^{+}~~\forall i\in \Omega \).

  3. 3

    i(t+h)Qij(t+h)≥i(t)Qij(t) and 1−i(t+h)(1−Qii(t+h))≥1−i(t)(1−Qii(t)) which is equivalent to

    $$\frac{Q_{ij}(t)\ell_{i}(t)}{Q_{ij}(t+h)}\leq \ell_{i}(t+h)\leq \frac{\ell_{i}(t)(1-Q_{ii}(t))}{1-Q_{ii}(t+h)}.$$

These risk premium adjustments can be obtained from the available market prices of risk free bonds and credit risky bonds of all the rating classes and of all the maturities..

Valuation of bond portfolio

Let μ0(s,T) and μj(s,T) denotes the price of risk-free discount bond and the price of risky discount bond with rating j at time s and with maturities T respectively. The price of risky bond is given by Jarrow et al. (1997)

$$\begin{array}{@{}rcl@{}} \mu_{j}(s,T)&=&\tilde{E}_{j,s}\left(e^{-\int_{s}^{T} r(u)du}(I_{[\tau_{j}>T]}+\delta I_{\{\tau_{j}\leq T\}})\right) \end{array} $$

where \(\tilde {E}_{j,s}\) denotes the conditional expectation (under the risk neutral probability measure \(\tilde {P}\)), given the information that at time s rating is j, τj represent the time of default of credit rating process \(\tilde {Z}\) when \(\tilde {Z}_{s}=j\), IA denotes the indicator function. It follows that

$$ \mu_{j}(s,T)=\mu_{0}(s,T)[\delta +(1-\delta) \tilde{P}_{s}(\tau_{j}> T)] $$

where \(\tilde {P}_{s}(A)=\tilde {E}_{j,s}(I_{A})\) is the probability that no default occurs till date T given the information that at time s rating is j, δ is the recovery rate of the risky discount bond. The claim holders get δ amount at the maturity of the contract if default occurs and receive face value if no default occurs. Here, it is assumed that recovery rate is a constant.

If sT, and if the credit rating of bond at time s i.e., Zs=j is known, we have

$$\begin{array}{@{}rcl@{}} \mu_{j}(s,T)= \left\{ \begin{array}{ccc} \frac{1}{\mu_{0}(T,s)} &\, \text{if} \,& j\neq 8 \\ \frac{\delta}{\mu_{0}(T,s)} & \,\text{if}\, & j=8\\ \end{array} \right.. \end{array} $$

Proposed methodology

Throughout this section, it is assumed that the present time is s and the risk horizon, i.e., the time at which portfolio is evaluated is t=s+1. Let Zn(s) denote the credit rating of asset n, n=1,2,…,N at time s and assume that they are independent to each other. Although the assumption of independence among the credit ratings of the bonds is very simplistic, several articles in the literature have justified this assumption. For instance, Kalkbrener et al. (2007) argued that the credit ratings of the bonds can be assumed uncorrelated if they are from different sectors of the financial markets. Incorporating the correlation among the credit ratings of the bonds could be a possible extension of the proposed framework.

Algorithm to generate the credit rating scenarios

In this paper, using Monte Carlo method, we generate future credit rating dynamics of a portfolio of credit risky bonds with the assumption that credit rating dynamics of bonds in the portfolio are independent of each other. Let Z=(Z1(t),Z2(t),…,ZN(t)) be the N-tuple vector where Zk(t) is the credit rating of the kth bond at time t. The algorithm for random sample generation of N-tuple credit rating vector, for time periods t=s+1,s+2,…,T, is as follows:

Step 1: Set t=s+1. Given initial credit rating \(Z^{n}(s)=z_{s}^{n}\), find the pmf and hence CDF of nth bond as follows:


Hence, the CDF of nth bond is given by

$$F_{z_{s}^{n}, i}(t):=P(Z^{n}(t)\leq i | Z^{n}(s)=z_{s}^{n})=\sum_{k=1}^{i}\phi_{z_{s}^{n},k}(t-s)$$

where \(F_{z_{s}^{n},i}(t)\) represent the probability of nth bond being in state less than equal to i at time t. Hence, pmf and CDF of nth bond at time 1 can be calculated once we know the initial rating and transition probability function.

Step 2: Generate N-tuple random vector, say u(s+1,N), which has uniform distribution in the interval [0,1].

Step 3: Find \(Z^{n}(s+1)=z_{s+1}^{n}\in \Omega \) such that

$$F_{z_{s}^{n}, z_{s+1}^{n}-1)}(t)< u(s+1,n)\leq F_{z_{s}^{n}, z_{s+1}^{n}}(t).$$

Set \(Z^{n}(s+1)=z_{s+1}^{n}\).

Step 4: Set t=s+2 and following the Step 1, obtain the pmf and CDF of each bond as in Step 1.

Step 5: Repeat the Step 2 and Step 3 to get \(Z^{n}(s+2)=z_{s+2}^{n}~~ \forall ~~ n=1,2,\ldots,N\).

Step 6: Increment t to t+1. Repeat Step 4 to get the next period ratings.

Step 7 If t+1=T, then stop. Otherwise repeat Steps 4, 5 and 6.

Repeat the mentioned algorithm until enough number of scenarios are obtained. Let \(\{Z^{n}_{k}(r);n=1,2,\ldots,N,k=1,2,\ldots,S\}\) be the credit rating of nth bond generated at time r in the kth scenario. Each generated scenario gives N×1 vector of credit ratings of N bonds.


This subsection explains the methodology to obtain the optimal portfolio of credit risky assets. Let S be the number of simulated scenarios of joint credit rating process.

  1. 1

    Estimate the one-step transition probability matrix ϕ(1)=[ϕi,j(1)]i,jΩ of continuous time-homogeneous semi-Markov model using the risk neutral measure.

  2. 2

    Given initial rating zj(0) of jth asset, j=1,2,…,N, find the one-step condition CDF as follows

    $$F_{j}(y)=P(Z^{j}(1)\leq y\mid Z^{j}(0)=z^{j}(0))=\sum_{k=1}^{y}\phi_{z^{j}(0),k}(1).$$
  3. 3

    Simulate S number of scenarios of the credit ratings following the methodology in “Algorithm to generate the credit rating scenarios” subsection. We have N×S matrix with (j,k) entry representing rating of jth asset at time 1 in kth scenario i.e., \(z_{k}^{j}(1)\).

  4. 4

    Given \(z_{k}^{j}(1)\) and zj(0), we obtain the price of bond at time 0 and 1 i.e. \(\mu _{z^{j}(0)}(0,T)\phantom {\dot {i}\!}\) and \(\phantom {\dot {i}\!}\mu _{z^{j}_{k}(1)}(1,T)\) for each j=1,2,…,N, k=1,2,…,S using Eq. (4).

  5. 5

    Find return of jth asset in kth scenario as follows

    $$r^{j}_{k}=\frac{\mu_{z^{j}_{k}(1)}(1,T)-\mu_{z^{j}(0)}(0,T)}{\mu_{z^{j}(0)}(0,T)},~\forall j=1,2,\ldots,N;k=1,2,\ldots,S$$

    where \(\mu _{z^{j}_{k}(1)}(1,T)\) are obtained in Step 4 above.

  6. 6

    Repeat the above process by moving the window 1 step ahead (from time 1 to time 2 and so on) until T time is reached.

  7. 7

    Solve the optimization problem (P)o and obtain the weights of each asset.

Empirical analysis

In this section, we illustrate the applicability of the proposed model using real data. We consider two different sectors namely industry sector and service sector. Further, we consider 10 credit risky bonds with same maturity of 9 years and these bonds are grouped into two sets of five bonds each and these two sets comes from two different sectors. We assume that the five bonds belonging to each sector have same transition probability matrix that is obtained assuming they follow the semi-Markov process. However, they differ in their initial credit rating (Tables 3 and 4). Similarly, we assume that the two bonds belonging to different sectors have different credit rating dynamics both obtained using semi-Markov process. We assume that the recovery rate for each of the bond is 0.

Table 1 2 step transition probability matrix for Industry Sector
Table 2 Two step transition probability matrix for Service Sector
Table 3 Average simulated returns for Service Sector
Table 4 Average simulated returns for Industry Sector

Considering the real data of historical ratings for two sectors, we estimate the parameters of the two semi-Markov models for two sectors. After estimating the parameters, the nth step transition probability matrices are obtained solving the Markov renewal equation. For instance, 2 step transition probability matrix for two sectors are given in Tables 1 and 2.

Using these transition probabilities matrices, we obtain CDFs for each rating category as discussed in the previous sections. We obtain 1000 scenarios of the future credit ratings for 10 bonds and for each period t=1,2,3,…,9 using CDFs obtained for the two sectors. Using the simulated scenarios, we obtain the price of the credit risky bonds and hence we find the returns. In the method of obtaining price of a bond for a given credit rating state, we need the transition probabilities in a risk neutral world. We apply the proposed change of measure to the historical kernel estimated from the data and obtain risk neutral transition probabilities. For the illustration purpose we have considered current yield for all the credit risky bonds and the risk free government bond from Akutsu et al. (2003) and risk premium adjustments from Kijima and Komoribayashi (1998). Average returns for each period is obtained taking the average of the returns simulated for the two sectors over all the scenarios. The average returns obtained are shown in Tables 3 and 4.

We obtain the optimal portfolio using the R software solving the min-max absolute deviation optimization problem. For the comparison purpose, we also obtain the future credit ratings scenarios and hence returns of credit risky bonds using the Markov chain model. The optimal weights of the assets are obtained by solving the optimization problem. The efficient frontier of min-max absolute deviation optimization model is shown in Fig. 1. It is obtained by solving the problem for different values of minimum return d. It is evident from Fig. 1 that the returns are better in case of semi-Markov model as compared to the Markov chain model. Further, for the comparison purpose, the average return, average risk and the average Sharpe ratio (the returns per unit risk taken) are obtained for both the portfolios and are shown in Table 5. It is evident that semi-Markov model performs better than Markov model with respect to all three measures.

Fig. 1
figure 1

Efficient frontier of min-max absolute deviation optimization model for SMP and Markov mdel

Table 5 Comparison of the results for two models

The model possesses relevant practical managerial implications. First, we notice that recent investigations proved that credit bond ratings can be jointly considered with market measures to optimally select financial portfolios, see Choi et al. (2020)). This strategy may overperform classical portfolios choices based only on market variables. We conjecture that the benefits may increase with the adoption of adequate rating models and the semi-Markovian proposal appears to be justified by credit rating data. Indeed, the results of the evaluation of the bond portfolio acknowledge that if the semi-Markov processes are incorporated to model the credit rating of the firms, the portfolios obtained performs better in comparison to the model where Markov chains are used (Singh and Dharmaraja 2017). Second, the evidence denotes that credit rating dynamics exhibit durations effects and accordingly managers could track important benefits by incorporating credit bond duration information in the portfolio selection procedure by avoiding for example too early or even unnecessary bond reallocations. Further, the other contribution of this article is the new risk premium adjustments, proposed for the pricing purposes, based on the general theory developed by Vasileiou and Vassiliou (2006). Since the credit risk management is one of the most important problems for investors in practical risk management, this article may be of great interest to the investors as it explicitly incorporates a firm’s credit rating, modelled through semi-Markov processes, for valuing debt securities. Finally, the proposed model can prove useful to banks and other financial intermediaries most concerned about the portfolio credit risk evaluation.

Conclusions and future work

In this article, we considered a portfolio optimization problem when portfolio consists of credit risky bonds. We considered l norm as the risk measure. To obtain the future returns of the bonds that are input to optimization model, we followed the approach of Jarrow et al. (1997) using credit ratings. In order to obtain the future credit ratings, we applied a semi-Markov credit rating model by D’Amico et al. (2005). The risk premium adjustments to obtain the risk neutral transition probabilities are proposed. A detailed algorithm is given to generate the credit ratings followed by the methodology to obtain the optimal portfolio using credit ratings. Extensive numerical analysis is given based on the real data in order to show the applicability of the model. Further, the returns obtained from the two models are compared based on the average return, average risk and average Sharpe ratio. One direction of the further extension of the present work is the incorporation of correlated credit rating dynamics of bonds.

Availability of data and materials

The datasets used and analysed during the current study are available from the corresponding author on reasonable request.



Semi-Markov processes


Conditional value at risk


Value at risk


Cumulative distribution function


Probability mass function


  • Akutsu, N, Kijima M, Komoribayashi K (2003) A portfolio optimization model for corporate bonds subject to credit risk. J Risk 6(2).

    Article  Google Scholar 

  • Andersson, F, Mausser H, Rosen D, Uryasev S (2001) Credit risk optimization with conditional value-at-risk criterion. Math Program 89(2):273–291.

    Article  Google Scholar 

  • Baena-Mirabete, S, Puig P (2018) Parsimonious higher order markov models for rating transitions. J R Stat Soc Ser A Stat Soc 181(1):107–131.

    Article  Google Scholar 

  • Baillo, A, Fernandez JL (2007) A simple Markov chain structure for the evolution of credit ratings. Appl Stochast Model Bus Ind 23(6):483–492.

    Article  Google Scholar 

  • Boreiko, D, Kaniovski S, Kaniovski Y, Pflug GC (2018) Business cycles and conditional credit-rating migration matrices. Q J Finan 8(04):1840005.

    Article  Google Scholar 

  • Cai, X, Teo K-L, Yang X, Zhou XY (2000) Portfolio optimization under a minimax rule. Manag Sci 46(7):957–972.

    Article  Google Scholar 

  • Carty, LV, Fons JS (1994) Measuring changes in corporate credit quality. J Fixed Income 4(1):27–41.

    Article  Google Scholar 

  • Centanni, S, Oliva I, Tardelli P (2017) Credit risk in an economy with new firms arrivals. Methodol Comput Appl Probab 19(3):891–912.

    Article  Google Scholar 

  • Choi, JY, Yi J, Yoon S-J (2020) A better criterion for forced selling in bond markets: Credit ratings versus credit spreads. Finan Res Lett:101437.

  • D’Amico, G, Janssen J, Manca R (2005) Homogeneous semi-Markov reliability models for credit risk management. Decis Econ Finan 28(2):79–93.

    Article  Google Scholar 

  • D’Amico, G, Janssen J, Manca R (2010) Initial and final backward and forward discrete time non-homogeneous semi-Markov credit risk models. Methodol Comput Appl Probab 12(2):215–225.

    Article  Google Scholar 

  • D’Amico, G, Janssen J, Manca R (2011) Discrete time non-homogeneous semi-Markov reliability transition credit risk models and the default distribution functions. Comput Econ 38(4):465–481.

    Article  Google Scholar 

  • D’Amico, G, Janssen J, Manca R (2012) Monounireducible nonhomogeneous continuous time semi-Markov processes applied to rating migration models. Adv Decis Sci 2012.

    Article  Google Scholar 

  • D’Amico, G, Janssen J, Manca R (2016) Non-homogeneous backward semi-Markov reliability approach to downward migration credit risk problem. J Oper Res Soc 67:393–401.

    Article  Google Scholar 

  • Dharmaraja, S, Pasricha P, Tardelli P (2017) Markov chain model with catastrophe to determine mean time to default of credit risky assets. J Stat Phys 169(4):876–888.

    Article  Google Scholar 

  • Duffie, D, Singleton KJ (2012) Credit Risk: Pricing, Measurement, and Management. Princeton University Press, Princeton.

    Google Scholar 

  • Frydman, H, Schuermann T (2008) Credit rating dynamics and Markov mixture models. J Bank Finan 32(6):1062–1075.

    Article  Google Scholar 

  • Grimshaw, SD, Alexander WP (2011) Markov chain models for delinquency: Transition matrix estimation and forecasting. Appl Stochast Model Bus Ind 27(3):267–279.

    Article  Google Scholar 

  • Hu, Y-T, Kiesel R, Perraudin W (2002) The estimation of transition matrices for sovereign credit ratings. J Bank Finan 26(7):1383–1406.

    Article  Google Scholar 

  • Jarrow, RA, Lando D, Turnbull SM (1997) A Markov model for the term structure of credit risk spreads. Rev Financ Stud 10(2):481–523.

    Article  Google Scholar 

  • Kalkbrener, M, Kennedy A, Popp M (2007) Efficient calculation of expected shortfall contributions in large credit portfolios. J Comput Finan 11(1):1–33.

    Article  Google Scholar 

  • Kavvathas, D (2001) Estimating credit rating transition probabilities for corporate bonds. afa 2001 new orleans meetings. Available at SSRN 252517.

  • Kijima, M, Komoribayashi K (1998) A Markov chain model for valuing credit risk derivatives. J Deriv 6(1):97–108.

    Article  Google Scholar 

  • Konno, H, Yamazaki H (1991) Mean-absolute deviation portfolio optimization model and its applications to tokyo stock market. Manag Sci 37(5):519–531.

    Article  Google Scholar 

  • Korolkiewicz, MW, Elliott RJ (2008) A hidden Markov model of credit quality. J Econ Dyn Control 32(12):3807–3819.

    Article  Google Scholar 

  • Kou, G, Peng Y, Wang G (2014) Evaluation of clustering algorithms for financial risk analysis using mcdm methods. Inf Sci 275:1–12.

    Article  Google Scholar 

  • Kulkarni, VG (2016) Modeling and Analysis of Stochastic Systems. CRC Press, New York.

    Google Scholar 

  • Lando, D, Skødeberg TM (2002) Analyzing rating transitions and rating drift with continuous observations. J Bank Finan 26(2-3):423–444.

    Article  Google Scholar 

  • Ma, Y, Zhang Z, Zhang W, Xu W (2015) Evaluating the default risk of bond portfolios with extreme value theory. Comput Econ 45(4):647–668.

    Article  Google Scholar 

  • Nickell, P, Perraudin W, Varotto S (2000) Stability of rating transitions. J Bank Finan 24(1-2):203–227.

    Article  Google Scholar 

  • Pasricha, P, Selvamuthu D, Arunachalam V (2017) Markov regenerative credit rating model. J Risk Finan 18(3):311–325.

    Article  Google Scholar 

  • Singh, A, Dharmaraja S (2017) A portfolio optimisation model for credit risky bonds with Markov model credit rating dynamics. Int J Finan Mark Deriv 6(2):102–119.

    Google Scholar 

  • Tardelli, P (2018) Probabilistic prediction of credit ratings: a filtering approach. Stochastics 90(4):504–523.

    Article  Google Scholar 

  • Vasileiou, A, Vassiliou P (2006) An inhomogeneous semi-Markov model for the term structure of credit risk spreads. Adv Appl Probab 38:171–198.

    Article  Google Scholar 

  • Young, MR (1998) A minimax portfolio selection rule with linear programming solution. Manag Sci 44(5):673–683.

    Article  Google Scholar 

  • Yu, F-H, Ching W-K, Gu J-W, Siu T-K (2017) Interacting default intensity with a hidden markov process. Quant Finan 17(5):781–794.

    Article  Google Scholar 

  • Yu, F-H, Lu J, Gu J-W, Ching W-K (2019) Modeling credit risk with hidden markov default intensity. Comput Econ 54(3):1213–1229.

    Article  Google Scholar 

Download references


This research received no specific grant from any funding agency in the public, commercial, or not-for-profit sectors.

Author information

Authors and Affiliations



We have no conflicts of interest to disclose. All the authors contributed equally to this work. All authors read and approved the final manuscript.

Corresponding author

Correspondence to Dharmaraja Selvamuthu.

Ethics declarations

Competing interests

The authors declare that they have no competing interests

Additional information

Publisher’s Note

Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Rights and permissions

Open Access This article is licensed under a Creative Commons Attribution 4.0 International License, which permits use, sharing, adaptation, distribution and reproduction in any medium or format, as long as you give appropriate credit to the original author(s) and the source, provide a link to the Creative Commons licence, and indicate if changes were made. The images or other third party material in this article are included in the article’s Creative Commons licence, unless indicated otherwise in a credit line to the material. If material is not included in the article’s Creative Commons licence and your intended use is not permitted by statutory regulation or exceeds the permitted use, you will need to obtain permission directly from the copyright holder. To view a copy of this licence, visit

Reprints and permissions

About this article

Check for updates. Verify currency and authenticity via CrossMark

Cite this article

Pasricha, P., Selvamuthu, D., D’Amico, G. et al. Portfolio optimization of credit risky bonds: a semi-Markov process approach. Financ Innov 6, 25 (2020).

Download citation

  • Received:

  • Accepted:

  • Published:

  • DOI: