Document Type : Original Article
Authors
 Shaghayegh Mahboubi Zadeh ^{1}
 Hassan Ghalibaf Asl ^{} ^{2}
^{1} MSc., Department of Financial Management, Faculty of Management and Economic, University of Alzahra, Tehran, Iran.
^{2} Associate Prof., Department of Management, Alzahra University, Tehran, Iran.
Abstract
Value at Risk model based on a switching regime approach was used in this study to optimize portfolios consisting of industry index (petroleum products, investment, chemical products, and metal products). For this purpose, the VaR of returns on index should first be extracted through parametric models of the (GARCH) family in each of the above industries by using regime transitions. After the risk of return on index is obtained for each industry, the optimal portfolio is created in the next step based on VaR minimization, and the optimal value of each industry is determined in the portfolio. According to the results, (MRSFIEGARCH) model had no superiority in VaR estimation over the other parametric models of the GARCH family. In fact (MSEGARCHt) was introduced as the optimal model. Among the designated industries, returns on indices followed regime transitions only in chemical products and investment by showing asymmetric reactions to external shocks. Moreover, the optimal weights were on the rise in the industries where VaR decreased over time, whereas the optimal weight of the portfolio decreased in the industries where VaR increased over time. The higher share of an optimal portfolio belonged to the industries where stock returns had lower rates of VaR. The riskreturnratio was employed to show that the optimal portfolio with a risk rate was measured by considering the switching regime was superior over the optimal portfolio with a risk rate extracted without considering the switching effects. To create an optimal portfolio, it is then recommended to make investments in the industries characterized by higher stability in prices and lower fluctuations in stock returns in the long run. This approach can be employed to obtain the best results from optimal portfolio preparation in the worstcase scenario of the market fluctuations.
Keywords
Introduction
Activities in financial markets are prone to risk and uncertainty, and investment risk is a major problem which an investor is faced within the stock market. Generally, investors seek to sustain lower risks and retain the stocks which have high returns and low risks. At the same time, many studies have shown that there is a positive correlation between risk and return; thus, a major challenge in portfolio preparation is to determine an optimal proportion or weight of the portfolio stocks for risk mitigation (Zolfaghari & Faghihian, 2018).
This is so important that various statistical methods and models have been proposed for quantitative risk measurement based on trading strategies in these markets. A common criterion proposed by financial analysts for risk measurement values at risk (VaR). In the novel financial theories, VaR is minimized (along with its derived indices) for portfolio preparation (Zolfaghari & Sahabi, 2016) to measure the risk of stock returns. In this technique, VaR is first extracted through parametric models of shortterm and longterm memories from the GARCH family ineffective and ineffective switching regime states for the stock indices of companies. After that, the optimal portfolio is created during 7–35day time horizons.
In this process, the most important task is to extract the risk time series. Although different methods have been proposed to measure the risk of stock returns in recent years, some researchers believe that these methods have considerable defects such as mere dependence on statistical methods and inattention to the regime behavior of stock prices (Barzegar & Faghihian, 2015). This process uses Markov switching to model shortterm and longterm memories from the GARCH family in addition to considering nonnormal distribution, symmetric and asymmetric reactions, and effects of the longterm memory on means and fluctuations of stock returns for the designated industries. Based on the Markov model, this process analyzes the regime transitions of stock returns and extracts the return risk time series if there are regime transitions.
According to the proposed structure, this paper seeks to answer the following questions:
 Is the ARFIMA–MRSFIEGARCH model superior to other parametric models in portfolio optimization?
 Is the stock return a function of regime transitions in the designated industries?
 Do the optimal weights of each of the designated industries change in the optimal investment portfolio over time?
Research background
Given the wide range of relevant studies, this section divides the research literature into three groups, the first of which includes the hybrid models of the MRS–GARCH family, whereas the second group includes only a few studies of VaR estimation through the models of the GARCH family. Finally, the third group pertains to portfolio optimization.
Torce et al. (2020) used MS–GARCH and MS–ARCH models to analyze the commercial status of coffee, sugar, and cocoa trades in future contracts. Their research results indicated that MS–ARCH–T was optimal for the future cocoa contract and that MS–GARCH of a Gaussian distribution was optimal for the future sugar contracts. However, they found no evidence showing that MS–GARCH was appropriate for coffee trades in the future market.
Sanzo (2018) used longterm memory and switching models to measure fluctuations in returns on crude oil. The research results showed that MS–AFIMA was superior over MS–GARCH in the extrapolation prediction of fluctuations in returns on crude oil. Moreover, longterm memory models of times series yielded better results through the switching approach than MS–GARCH.
In their paper, Kaporal and Zekich (2018) employed MS–GARCH to model fluctuations in cryptocurrencies. According to their results, standard GARCH models might fail to predict VaR properly. Hence, using asymmetric effects and Markov switching can provide investors with better estimates.
Zolfaghari and Sahabi (2017) employed MS–GARCH models to measure VaR for the stock indices of oil products under normal, tstudent, and generalized error distributions. Their research data belonged to the 26/06/2012–23/07/2016 period. According to their results, MS–GARCH models outperformed ARMA–GARCH models.
Almasi et al. (2018) used MS–FITGARCH to model the longterm memory and analyze oil shocks in the Tehran Stock Exchange through monthly data belonging to the 1998–2017 period. Their research results indicated that MS–FITGARCH showed the significant, positive effects of oil price shocks only on the mean of stock returns in prosperity regimes. In fact, these effects were insignificant in recession regimes.
Rostami et al. (2018) submitted a paper entitled Modeling Oil Fluctuations through Switching. They used the singleregime and multiregime MS–GARCH models to estimate oil price fluctuations. According to their findings, a tripleregime model was accepted to explain the behavior of a variable within the research period.
Charles Manasi et al. (2019) analyzed the mutual effects of stock prices and exchange rates through multivariate GARCH–VaR models. Their results indicated a longterm and stable relationship between stock prices and exchange rates. GARCH–VaR can also be employed to state that there is a considerable mean of fluctuation overhead from the stock market to the currency market, but not vice versa.
Using GARCH models to predict market fluctuations, Azliana et al. (2018) estimated VaR in both Islamic and conventional stock markets in Malaysia. They employed GARCH, CGARCH, and TGARCH to estimate VaR. According to their results, TGARCH of normal distribution was the best risk estimation model in Islamic and conventional stock markets.
In a paper, Moghadam (2016) adopted an optimal method to calculate VaR of investment funds by using a parametric method, the Monte Carlo method, and a historical simulation to measure VaR at 14 investment funds. The results of the Kupiec, Christoffersen, and Hendricks tests at confidence levels of 99% and 95% indicated that the Monte Carlo method was superior over other techniques in predicting potential losses of investment funds.
Shawalpour et al. (2016) used CGARCH, GARCH, and EGARCH to calculate different VaR density distribution functions of OPEC crude oil. According to their results, CGARCH outperformed the other models by measuring the prediction error through tstudent distribution criteria for predicting fluctuations and calculating VaR.
Vladimir Ranković et al. (2016) integrated the univariate GARCH and VaR for investment portfolio optimization. Their research results indicated high and low fluctuations in samples. Moreover, the univariate GARCH integrated with VaR outperformed the multivariate GARCH integrated with VaR in portfolio selection.
Yu et al. (2011) prepared the optimal portfolios of MS and Google within the conditional VaRmean framework. Their results showed that the selected portfolio returns matched the returns on the variancemean model portfolio; however, the latter entailed higher risks.
Najafi et al. (2017) analyzed the portfolio selection problem through conditional VaR, which they compared with the interval approach by considering uncertainty as opposed to certainty. According to their results, the proposed method outperformed the certain state. Moreover, the uncertain state showed stricter limitations than the strict state.
Asgharpour and Reza Zadeh (2015) submitted a paper entitled Optimization of Stocks in Food Industries in which they used VaR. Their results indicated that the majority of capitals were allocated to the stocks of companies having the highest expected returns and the lowest VaR.
In another paper entitled Determining Optimal Portfolio of Stocks in Food Industries within VaR Framework, Asgharpour and Reza Zadeh (2014) used MRS–GARCH and bootstrapping methods. According to their results, the optimal portfolio had higher weights in both methods. This indicated the high and low rates of VaR.
Research Methods
In this method, the portfolio optimization principles resemble the Markowitz model; the difference is that investors seek lower VaR and higher returns (Bo, 2001). The problem must be solved through Equation 1 to obtain the optimal portfolio, i.e. optimal weights of each share and optimal portfolio VaR:
𝑀𝑖𝑛 𝑉𝑎𝑅 𝑝,
S.t. , i=1, …, n (1)
In this equation, shows the portfolio VaR, and all the necessary pieces of information are available (VaR of each share, return mean of each share, and total returns of portfolios, i.e. weights of assets in the initial or existing portfolio). Moreover, refers to the weights of assets in the unknown portfolio.
As mentioned earlier, VaR is measured through MRS–GARCH models depicted in the following figure.
Arfima Model
ARMA and ARIMA models do not consider longterm memory properties. Therefore, To take into account the role of longterm memory in the return process, the autoregressive fractionally integrated moving average (ARFIMA) model is presented by (Granger at al , 1983).
(2)
Where L is lag operator, d is the fractional difference operator taking long memory, x is a white noise process with zero mean and constant variance, is the return mean. If therefore this process is stationary, is autocorrelation function and is moving average function (where both are p lags).
GARCH Models
General GARCH models are widely used in the estimation of volatility in the financial markets. Simple GARCH model shows us that volatilities are not constant over time. In this study, we used the standard specifications of the GARCH, EGARCH, IGARCH, FIGARCH, and FIEGARCH models under two types of distributions tStudent and GED.
GARCH Model
(3)
Where و ، and To better define the conditional variance of the GARCH model, all coefficients must be positive.
IGARCH Model
(4)
EGARCH Model:
By entering asymmetric reactions of time series to external shocks, EGARCH model is introduced. the asymmetric effect of positive and negative shocks to the GARCH model, EGARCH model is obtained (Nelson 1991).
(5)
is a leverage effect, is the conditional variance , is the error at t.
FIGARCH Model
To illustrate the longterm memory of financial market volatility, Bailey (1996) introduced the FIGARCH model by substituting a variable operator (1L)with a fractional operator variable , . The FIGARCH (1, d,1) model is described as follows:
(6)
is the error at time t and is the conditional variance of at time t, L is the lag operator. is the fractional differencing operator. d is the long memory parameter in volatility and When 0 < d < 1 We have a stationary long memory process. (Baillie et al., 1996).
FIEGARCH Model
FIEGARCH (exponential FIGARCH) model is proposed by Bollerslev and Mikkelsen (1996), Which adds the asymmetric effect of positive and negative shocks to the FIGARCH model. They also proved that the FIEGARCH model for 0 <d <1 is stationary.
(7)
and the first part is the effect of the symbol and the second part i.e. is the effect of the shock value. is the fractional differencing operator. d is the long memory parameter in volatility. If d=0 the FIEGARCH model becomes the conventional EGARCH model and IEGARCH model for d=1.When = 0, a leverage effect is allowed. (Bollerslev and Mikkelsen 1996).
Markov Switching (MRS) Model
Markov Switching model is first proposed by Hamilton (1988,1989,1994). which allows all parameters of financial series to switch between to state. The transition probability represents the probability of switching from state i at t1 to state j at t:
for i,j=1,2,…,s (8)
is the transition probability or moving from state i to state j.
In other words, the sequence { } is assumed to be a stationary, irreducible
Markov process with discrete state space {1, 2} and depends on the state of the economy and periods of a recession takes zero and boom takes one. We constrain that < , and states 1 and 2 stand for the low and highvolatility states, respectively. The parameters in which case the transition probability matrix P (2×2) can be as follows (Hamilton,1989):
(9)
(10)
is information parameters at time t1, is the vector of parameters, is the filtered probability in state i at time t1 is equal (Hamilton,1989).
The current regime is dependent on the regime of the previous period, also p indicates the probability that the economy will change from state one to state zero at time t. all of the variables of the MRSARFIMA, MSR GARCH, MSREGARCH, MSRIGARCH, MSRFIGARCH, MRSFIEGARCH model are estimated using the maximum likelihood estimation (MLE) Explained in (Shi et al. 2015) (Haas et al,2004) (Ho et al. 2013).
MRSARFIMA Model
MRSARFIMA model is proposed by Haas et al. (2004), Haas (2009), Ho
et al (2013). Shi et al (2015) by including MRS process in FIGARCHE model, The MRSARFIMA model is presented with two GED and tstudent distributions as follows.
(11)
Where
(12)
L is lag operator; d is long memory parameter can switch between two states. is the return mean. If therefore this process is stationary, is autocorrelation function and is Moving average function (where both are p lags). It should be noted and and can switch between two states.
MRS GARCH model consists of four main parameters: conditional mean, conditional variance, conditional distribution, and regime process. Because the main purpose of the article is to measure and volatility forecasts the conditional mean simply modeled as:
(13)
Where, i =1, 2 , and are zero mean and unit variance processes. For GARCH model The conditional variance for , Generally, the MRSGARCH model can be written as follows :
(14)
Where, is a mean of past conditional variances(Mariucci, 2005).
MRSEGARCH Model
The exponential switching GARCH model can be written as equation (15) below:
(15)
That has an independent and the same distribution (i.i.d.) With zero mean and unit variance.
(16)
Conditional variance follows an EGARCH process.log( the conditional variance is approximate and completely positive and has no need for the nonnegative constraints used in GARCH models. This conditional variance equation shows the asymmetric effect of negative news on variance or leverage effect with coefficient θ (Sarang, 2014).
MRSFIGARCH Model
The MRSFIGARCH model was first proposed by Shi et al (2013). This extended model is extended of MRSGARCH models which was previously used by (Hamilton, 1989). we use MRS FIGARCHE model under two distributions of tStudent and generalized error(GED) to measure value at risk of stock returns, which is as follows:
MRSFIEGARCH Model
The MRSFIEGARCH model was first proposed by Shi et al (2020). This extended model is extended of MRSGARCH models which was previously used by (Hamilton, 1989). we use MRS FIGARCHE model under two distributions of tStudent and generalized error(GED) to measure value at risk of stock returns, is an innovation of this research., which is as follows:
(19)
(20)
tStudent and GED can affect fattail behaviors and leptokurtic behavior, both of these distributions are widely used in financial science in the GARCH family models (Shi and Feng, 2016). Also, in this research, we have used tstudent and GED distributions, the density functions are provided as follows:
based on previous studies by entering asymmetric reactions of time series to external shocks, EGARCH model is introduced. however, it should be considered that EGARCH model does not include longterm memory in modeling fluctuations, so to overcome this limitation, the FIEGARCH model has been introduced. however, most models used up to now for share behavior have been based on linear or nonlinear models. Therefore, FIEGARCH models are more accurate in showing some statistical properties of the data such as long memory, fat tail, clustering of variances, and Show when the stock market is more volatile or calmer. On the other hand, Linear models are Unable to explain nonlinear behaviors such as asymmetry, Therefore, nonlinear Markov switching model is used. Since this model is known as the regime change model, it uses several equations to explain the variable behavior in different regimes. Since this model is known as the regime change model which uses several equations to explain the variable behavior in different regimes. The reason for the term regime change is used. That is, a policy variable may exhibit one behavior at a given time and another at another time. in this study, we use the MRSFIEGARCH model with two distributions of tStudent and GED to modeling stock fluctuations and predict its price to form an optimal portfolio.
Due to the limited space of the present article to discuss the theoretical foundations regarding GARCH family models, distribution functions, and Markov switching it is suggested to see Ref. 20 for more information because the research background is not reviewed further here.
Research Findings
The data used in this research are the daily stock prices of selected industries including metal products, chemical products, petroleum products, investment from 2008/12/14 to 2019/06/10these series are sourced from the Tehran Stock Exchange (TSE) database. The logarithmic return was employed to calculate return . In this equation, indicates the price on the t th day. Descriptive statistics of return time series of indices are presented in table 1.
Table 1. Descriptive statistics of return variables for industries
study period 
Descriptive statistics 
metal products 
petroleum products 
chemical products 
investment 
2008/12/142019/06/10 
Average 
0.0013 
0.0015 
0.0015 
0.0012 
Standard deviation 
0.016 
0.021 
0.010 
0.010 

Skewness 
0.84 
9.19 
0.69 
0.48 

Kurtosis 
12.87 
320.63 
9.99 
5.18 

JarqueBera [1] Statistic 
9867.44 
.9954088 
5001.21 
567.18 

JarqueBera Possibility 
0.000 
0.000 
0.000 
0.000 

Number of observations 
2360 
2360 
2360 
2360 
According to this table, the indices of all industries, except for oil products, are skewed to the left and have higher kurtosis than standard; therefore, these statistics show that the daily returns of the designated industries do not follow a normal distribution.
Time Series Durability Test
In the time series reliability analysis, if the sustained shock effect is permanent, the time series has a complete longterm memory. If the shock effect remains for a rather long time, the corresponding time series has a fractional root with longterm memory. However, if the momentum effect wears off quickly, the time series have a shortterm memory (Najafi Moghadam, 2016). The augmented DickeyFuller (ADF) test was employed to conduct the unit root test on return time series. In this test, the null hypothesis is the existence of the unit root:
Table 2. Durability test based on ADF and the PP test
Philips–Peron test 
Generalized DickeyFuller test 
industry 

40.24 
Test statistic 
38.49 
Test statistic 
metal products 

3.432 
1% 
Critical value of the test 
3.432 
1% 
Critical value of the test 

2.862 
5% 
2.862 
5% 

2.567 
10% 
2.567 
10% 

42.69 
Test statistic 
42.53 
Test statistic 
petroleum products 

3.432 
1% 
Critical value of the test 
3.432 
1% 
Critical value of the test 

2.862 
5% 
2.862 
5% 

2.567 
10% 
2.567 
10% 

21.526 
Test statistic 
34.67 
test statistic 
investment 

3.432 
%1 
Critical value of the test 
3.432 
%1 
Critical value of the test 

2.862 
%5 
2.862 
%5 

2.567 
%10 
2.567 
%10 

34.729 
Test statistic 
22.574 
Test statistic 
chemical products 

3.432 
%1 
Critical value of the test 
3.432 
%1 
Critical value of the test 

2.862 
%5 
2.862 
%5 

2.567 
%10 
2.567 
%10 
The statistics obtained from the ADF and the Philips–Peron (PP) tests are smaller than the critical values of the significance level. Therefore, the null hypothesis stating the existence of the unit root is rejected, and durability is true.
Heteroscedasticity Test
The Lagrange multiplier test was used on the residuals of this time series with 10 delays. Table (3) shows the heteroscedasticity test results:
Table 3. Conditional heteroscedasticity test
industry 
test ARCH 
test statistic 
probability 
chemical products 
statistic F 
47.37 
0.000 

175.53 
0.000 

investment 
F statistic 
104.22 
0.000 

34.07 
0.000 

petroleum products 
F statistic 
0.35 
1.000 

1.41 
1.000 

metal products 
F statistic 
0.46 
0.91 
4.62 
0.91 
Considering F and chisquared statistics, chemical products and investment industries had autoregressive conditional heteroscedasticity (ARCH) effects; therefore, they are dealt with in the next steps for modeling conditional heteroscedasticity. Moreover, only mean models will be estimated for oil products and metal products.
LongTerm Memory
The Gewek–Porter–Hudak (GPH) test is employed to determine the existence of longterm memory in the time series of the selected industries. If the test statistic is not significantly different from zero, the null hypothesis stating the nonexistence of longterm memory cannot be rejected. Table 4 shows the results of using this test:
Table 4. GPH test results
t statistic 
probability 
d 
industry 
0.0196 
0.000 
0.07 
petroleum products 
0.0196 
0.000 
0.19 
investment 
0.0189 
0.000 
0.09 
metal products 
0.0196 
0.00 
0.16 
chemical products 
According to the GPH test value, the existence of longterm memory is confirmed in returns on the index of each industry at a confidence level of 10%. At the same time, a positive value of lower than 0.5 was obtained for the longterm memory parameter; therefore, the durability (d) of time series is reconfirmed for the return variables of all industries. As a result, ARMA(p,q) becomes ARFIMA(p,d,q).
In the next step, the three BoxJenkins steps were taken to perform the ARFIMA modeling process. After that, the Hannan–Quinn criterion (HQC) was revised. The final model of the indices of industries are as follows:
Table 5. Optimal delay determination of equations for the designated industries
average time series model of selected industries 
industry 
ARFIMA(1,d,0) 
petroleum products 
ARFIMA(1,d,0) 
metal products 
ARFIMA(1,d,2) 
chemical products 
ARFIMA(1,d,1) 
investment 
Estimation of GARCH Models
Table 6. GARCH models of the chemical product industry
model 
Distribution 
parameter 
dARFIMA 
AR(1) 
MA(1) 
MA(2) 
dFIGARCH 
α 
β 


GARCH 
tstudent 
Coefficient 
0.48 
0.49 
0.62 
0.13 
 
0.42 
0.76 
 
 
tstatistic 
14.01 
6.586 
6.813 
4.285 
 
3.401 
16.97 
 
 

GED 
Coefficient 
0.51 
0.58 
0.69 
0.14 
 
0.15 
0.84 
 
 

tstatistic 
6.036 
5.464 
4.541 
2.355 
 
3.94 
24.73 
 
 

EGARCH 
tstudent 
Coefficient 
0.11 
0.42 
0.2 
0.11 
 
0.18 
0.99 
0.036 
1.00 
tstatistic 
14.69 
2.841 
1.413 
3.466 
 
1.506 
1.049 
0.73 
5.821 

GED 
Coefficient 
0.0068 
0.99 
0.60 
0.34 
 
0.27 
0.99 
0.11 
0.41 

tstatistic 
0.046 
279.3 
7.22 
5.032 
 
1.688 
664.1 
2.291 
6.164 

IGARCH 
tstudent 
Coefficient 
0.49 
0.49 
0.62 
0.13 
 
0.20 
0.79 
 
 
tstatistic 
13.18 
6.513 
6.713 
4.087 
 
5.176 
 
 
 

GED 
Coefficient 
0.095 
0.96 
0.66 
0.27 
 
0.155 
0.84 



tstatistic 
2.099 
18.49 
8.473 
6.557 
 
4.321 
 



FIGARCH 
tstudent 
Coefficient 
0.49 
0.49 
0.62 
0.14 
0.63 
0.36 
0.67 
 
 
tstatistic 
13.59 
7.48 
7.665 
4.519 
7.881 
3.686 
5.824 
 
 

GED 
Coefficient 
0.51 
0.5 
0.61 
0.16 
0.66 
0.31 
0.74 
 
 

tstatistic 
8.623 
4.760 
4.364 
3.310 
4.545 
2.874 
6.976 
 
 

FIEGARCH 
tstudent 
Coefficient 
0.89 
0.20 
0.69 
0.23 
0.48 
0.54 
0.90 
0.08 
0.40 
tstatistic 
87.95 
17.88 
64.84 
23.42 
5.916 
3.36 
22.58 
2.58 
6.551 

GED

Coefficient 
0.89 
0.203 
0.69 
0.23 
0.48 
0.54 
0.90

0.08 
0.40 

tstatistic 
86.48 
17.40 
63.92 
22.98 
5.917 
3.364 
22.58 
2.584 
6.551 
Table 7. GARCH models of the investment industry
model 
Distribution 
parameter 
dARFIMA 
AR(1) 
MA(1) 
MA(2) 
dFIGARCH 
α 
β 


GARCH 
tstudent 
Coefficient 
0.12 
0.24 
0.46 
 
 
0.18 
0.81 
 
 
tstatistic 
4.281 
2.394 
5.668 
 
 
6.57 
31.28 
 
 

GED 
Coefficient 
0.128 
0.25 
0.47 
 
 
0.18 
0.819 
 
 

tstatistic 
4.052 
2.449 
5.932 
 
 
6.963 
32.29 
 
 

EGARCH 
tstudent 
Coefficient 
0.13 
0.076 
0.46 
 
 
0.029 
0.99 
0.033 
0.59 
tstatistic 
56.95 
27.67 
51.95 
 
 
0.32 
0.1052 
1.626 
9.27 

GED 
Coefficient 
0.127 
0.26 
0.49 
 
 
0.032 
0.998 
0.033 
0.53 

tstatistic 
3.911 
2.514 
6.059 
 
 
0.34 
1244 
1.73 
9.485 

IGARCH 
tstudent 
Coefficient 
0.128 
0.24 
0.47 
 
 
0.18 
0.81 
 
 
tstatistic 
4.25 
2.38 
5.64 
 
 
6.96 
4.25 
 
 

GED 
Coefficient 
0.128 
0.25 
0.47 
 
 
0.18 
0.81 
 
 

tstatistic 
4.069 
2.48 
6.011 
 
 
7.301 
 
 
 

FIGARCH 
tstudent 
Coefficient 
0.12 
0.24 
0.47 
 
0.46 
0.002 
0.005 
 
 
tstatistic 
3.788 
2.225 
5.28 
 
8.706 
3.275 
6.102 
 
 

GED 
Coefficient 
0.12 
0.25 
0.47 
 
0.46 
0.20 
0.505 
 
 

tstatistic 
3.657 
2.339 
5.66 
 
1.654 
7.434 
3.747 
6.180 
 

FIEGARCH 
tstudent 
Coefficient 
0.128 
0.24 
0.46 

0.67 
0.73 
0.91 
0.029 
0.64 
tstatistic 
4.33 
2.293 
4.764 
 
12.80 
9.226 
47.89 
1.304 
13.03 

GED

Coefficient 
0.127 
0.25 
0.47 
 
0.704 
0.73 
0.916 
0.028 
0606 

tstatistic 
8.977 
6.972 
16.35 
 
13.20 
9.95 
25.57 
1.31 
13.00 
After the effects of ARCH and GARCH were confirmed on chemical products and investment industries, five GARCH models were estimated through two distributions tstudent and GED[2]. In total, 10 models were analyzed. The following table shows the estimated models of mean and conditional variance for the above two industries.
According to a review of all the estimated models for the designated industries based on tstudent and GED distributions, the conditional variance followed the GARCH structure in all industries. Moreover, all the mean and variance coefficients were significant at a confidence level of 10% based on the t statistics. Table (6) and (7) demonstrates the results of ARFIMAGARCH models for the chemical industry.
Estimation of Markov Switching Models
Among all the designated industries, two industries lacked the ARCH effect; therefore, their mean models were estimated without considering their variance models. Table (8) shows the mean model results of oil products and metal products by considering the switching effect. Furthermore, the numbers inside parentheses indicate the regime, whereas the numbers outside parentheses indicate the model delays.
Table 8. Estimation of Markov switching mean models for three industries lacking ARCH effects
industry 
Parameter 
C(1) 
C(2) 
AR(1) 
AR(2) 
MA1(1) 
MA1(2) 
MA2(1) 
MA2(2) 




LL 
petroleum products 
Coefficients 
0.00 
0.00 
0.01 
0.34 
 
 
 
 
0.07 
0.08 
0.12 
0.7 
5754.1 
Standard deviation 
0.16 
0.07 
3.24 
6.16 
 
 
 
 
5.98 
6.54 
45.2 
0.2 

t student statistic 
0.09 
2.6 
0.47 
5.51 
 
 
 
 
4.37 
8.56 
 
 

metal products 
Coefficients 
0.00 
0.1 
0.28 
0.36 
 
 
 
 
0.09 
0.81 
0.99 
 
6475.9 
Standard deviation 
0.04 
0.57 
1.98 
24.9 
 
 
 
 
4.98 
13.3 
0.12 
 

t student statistic 
2.26 
18.1 
14.5 
1.45 
 
 
 
 
5.65 
8.97 
 
 
According to the results and considering the insignificant coefficients of variables for the previous period in the regime, both industries (metal products and oil products) are under no effects of the switching regime. After GARCH models were estimated for chemical products and investment industries, each model was estimated by the switching regime. Table (9) demonstrates the results of estimating Markov switchingGARCH models for the chemical industry.
Table 9. MRS–GARCH models of the chemical industry
model 
Distribution 












LL 
GARCH 
t student 
0.0 
0.3 
0.007 
0.07 
 
 
 
 
0.93 
0.91 
0.88 
0.91 
8150.8 
GED 
0.0 
0.00 
0.005 
0.053 
 
 
 
 
0.95 
0.93 
0.92 
0.93 
8143.7 

EGARCH 
t student 
0.01 
0.01 
0.25 
0.01 
0.21 
0.25 
 
 
0.33 
0.65 
0.02 
0.98 
9956.2 
GED 
0.01 
0.012 
0.32 
0.03 
0.54 
0.65 
 
 
0.66 
0.55 
0.33 
0.97 
9859.2 

IGARCH 
t student 
0.00 
0.015 
0.33 
0.34 
 
 
 
 
0.55 
0.45 
0.006 
0.99 
9566.2 
GED 
0.00 
0.005 
0.35 
0.01 
 
 
 
 
0.54 
0.65 
0.01 
0.98 
6054.3 

FIGARCH 
t student 
0.00 
0.002 
0.032 
0.32 
 
 
0.6 
0.65 
0.002 
0.02 
0.82 
0.98 
8565.2 
GED 
0.00 
0.005 
0.004 
0.29 
 
 
0.4 
0.44 
0.03 
0.026 
0.68 
0.96 
8032.6 

FIEGARCH 
t student 
0.00 
0.003 
0.006 
0.4 3 
0.67 
0.69 
0.63 
0.68 
0.047 
0.76 
0.78 
0.89 
7659.40 
GED 
0.00 
0.0031 
0.008 
0.21 
0.70 
0.73 
0. 51 
0.53 
0.04 
0.59 
0.66 
0.83 
7027.31 
Table 10. MRS–GARCH models of the investment industry
model 
Distribution 












LL 
GARCH 
t student 
0.00 
0.00 
0.13 
0.7 
 
 
 
 
0.84 
0.08 
0.80 
0.63 
7859.6 
GED 
0.00 
0.00 
0.10 
0.6 
 
 
 
 
0.87 
0.07 
0.84 
0.50 
7869.6 

EGARCH 
t student 
0.01 
0.03 
0.36 
0.02 
0.65 
0.25 
 
 
0.55 
0.56 
0.01 
0.87 
9956.2 
GED 
2.3 
0.01 
0.12 
0.32 
0.32 
0.33 
 
 
0.56 
0.26 
0.25 
0.97 
9658.2 

IGARCH 
t student 
0.00 
0.01 
0.22 
0.32 
 
 
 
 
0.65 
0.55 
0.002 
0.95 
8545.2 
GED 
1.02 
0.01 
0.34 
0.33 
 
 
 
 
0.55 
0.44 
0.006 
0.96 
9565.2 

FIGARCH 
t student 
0.22 
0.006 
0.10 
0.65 
 
 
0.65 
0.02 
0.85 
0.05 
0.32 
0.34 
8452.0 
GED 
0.25 
0.016 
0.21 
0.55 
 
 
0.64 
0.03 
0.84 
0.12 
0.42 
0.27 
8250.5 

FIEGARCH 
t student 
0.00 
0.003 
0.112 
0.51 
0.56 
0.27 
0.70 
0.09 
0.74 
0.10 
0.12 
0.89 
7332.50 
GED 
0.00 
0.004 
0.30 
0.43 
0.31 
0.25 
0.63 
0.04 
0.71 
0.13 
0.06 
0.90 
7173.80 
In the above tables, and indicate yintercepts of all models in Regime 1 and Regime 2, respectively. Moreover, and show the values about the variances of the previous period ( ) in conditional variance models in Regime 1 and Regime 2, respectively. Moreover, and refer to the values of squared disruptive expressions of GARCH and IGARCH, respectively, showing the coefficient of in EGARCH. Parameters and indicate the leverage coefficients in EGARCH, and θ shows the long memory coefficient in the conditional variance model. According to the results of estimating the models presented in the above table, all of the above coefficients are significant at a confidence level of 10% in both regimes.
Determining Optimal Model for Industry
After five models were estimated for investment, chemical, and automotive industries simply under the switching assumption, the appropriate VaR estimation model was determined. For this purpose, the model with the maximum likelihood logarithm value was selected in each industry. Based on the Garcia–Perron likelihood ratio test for distribution functions, the optimal model was then extracted. Tables 11 and 12 show the results of these tests.
Table 11. Results of the Garcia–Perron likelihood ratio test in GARCH models without considering the switching effect
industry 
GARCH 

Test statistic 
GED 
t 

investmenrt 
15.82 
7974.21 
7982 

chemical products 
731.62 
7870.06 
8235.87 

industry 
IGARCH 

Test statistic 
GED 
t 

investment 
12.4 
7455.1 
7461.3 

chemical products 
670.48 
7384.36 
7719.6 

industry 
EGARCH 

Test statistic 
GED 
t 

investmenrt 
1007.42 
7860.9 
7357.19 

chemical products 
881.44 
7261.81 
7702.53 

industry 
FIGARCH 

Test statistic 
GED 
t 

investmenrt 
20.5 
7975 
7985.25 

chemical products 
720.52 
7911.08 
8271.35 

industry 
FIEGRACH 

Test statistic 
GED 
t 

investmenrt 
26.7 
7860.68 
7874.02 

chemical products 
845.74 
7763.54 
8186.41 

According to the above table, FIGARCH yielded the maximum likelihood logarithm value among the other estimated models in the chemical and investment industries, in which it is considered the optimal model. In the next step, exceeded at the 5% level; therefore, t student distribution was selected as the optimal distribution of stock returns in the investment industry. The steps in determining the optimal model and distribution for the stock return variable of the designated industries in the presence of switching effects are similar to those in the absence of switching effects.
Table 12. Results of the Garcia–Perron likelihood ratio test in GARCH models by considering switching effects
industry 
GARCH 

Test statistic 
GED 
t 

investment 
99.19 
7869.66 
7859.663 

chemical products 
14.226 
8143.766 
8150.87 

industry 
IGARCH 

Test statistic 
GED 
t 

investment 
2040.0 
9565.22 
8545.22 

chemical products 
7023.82 
6054.32 
9566.23 

industry 
EGARCH 

Test statistic 
GED 
t 

investment 
595.956 
9658.254 
9956.232 

chemical products 
194.011 
9859.226 
9956.232 

industry 
FIGARCH 

Test statistic 
GED 
t 

investment 
28.032 
7054.65 
7069.658 

chemical products 
66.27 
7032.65 
7065.78 

industry 
FIEGARCH 

Test statistic 
GED 
t 

investment 
317.14 
7173.80 
7332.50 

chemical products 
1264.18 
7027.31 
7659.40 

Determining Final Optimal Models for Designated Industries
In this step, the optimal model and distribution are selected for each of the two industries in both switching and nonswitching states through the above test. Table 13 indicates optimal models for the chemical products and investment industries having ARCH effects.
Table 13. Determining the final optimal model for the industries with ARCH effects
industry 
Optimal models without switching effect 
Optimal models with switching effect 
statistic 

chemical products 
FIGARCHt 

EGARCHt 

3369.769 
8271.35 
9956.232 

investment 
FIGARCHt 
7985.25 
EGARCHt 
9956.232 
3941.964 
Considering the test statistic, it can be concluded that all values exceeded at the 5% confidence level. In other words, the EGARCHt model is optimal for each of the above industries by considering the switching model effects.
VaR Measurement in Designated Industries
After the optimal model and distribution are were determined for each industry through VaR calculation, the total index of fluctuations in the optimal model of each industry to measure the daily VaR of each industry at the 95% confidence level. Therefore, VaR values can be extracted from the following equations.
(21)
In this equation, µ indicates the mean returns on indices of different industries, whereas h refers to the time series of stock returns in different industries, and shows the critical value of the normal distribution. Figures 1 and 2 show the VaR of the return rate in different industries within the 2008/12/14–2019/06/10 period. Moreover, the VaR diagrams for oil products and chemical products can be found in Appendix B in Ref. 13.
Metal Products Industry
Since this industry lacks ARCH effects and follows one regime, its trend is analyzed through simple modeling. According to Figure (1), there is no relationship between the return disruption components of this industry, and there is no complicated process in return. Therefore, the risk of this industry was below 0.06% of loss during the research period.
Figure 1. VaR of the metal products industry
Investment Industry
According to a review of the risk time series in this industry as shown in Figure 4, the loss rate range between 1% and 2.5% within the 2008–2019 period. In fact, the investment industry risk showed a descending trend from September 2016 to September 2018.
Figure 2. VaR of the investment industry
VaR Estimation in All Designated Industries
After VaR was calculated in each of the designated industries by using the sliding window method, the corresponding VaR time series was estimated for a 7–35week period in both effective and ineffective switching regimes. Finally, the resultant values were employed to calculate the portfolio VaR in that period. Table 14 &15 shows the results of VaR for stock indices of the industries.
Table 14. Predicting the switching regime VaR in the 7–35week time horizon for the designated industries
time horizon 
investment 
metal products 
petroleum products 
chemical products 
7 
2.3 
3.05 
4.91 
2.28 
14 
1.62 
1.71 
5.74 
1.71 
21 
1.43 
2.15 
3.48 
1.61 
28 
1.37 
3.77 
1.98 
1.77 
35 
1.21 
2.36 
4.55 
1.66 
Table 15. Predicting the nonregime VaR of indices for the designated industries in the 7–35week time horizon
time horizon 
investment 
metal products 
petroleum products 
chemical products 
7 
1.61 
3.05 
4.91 
1.60 
14 
1.52 
1.71 
5.74 
1.38 
21 
1.84 
2.15 
3.48 
1.86 
28 
1.78 
3.77 
1.98 
1.74 
35 
1.50 
2.36 
4.55 
1.66 
Determining Optimal Investment Portfolio
In this section, Equation 1 was employed to develop an optimal portfolio with an emphasis on the portfolio VaR minimization. For this purpose, the correlation matrix was created for the indices of the designated industries. Table 16 presents the results of this matrix.
Table 16. Correlation matrix for stock returns of indices in the designated industries
industry 
investment 
metal products 
chemical products 
petroleum products 
investment 
1 



metal products 
0.37 
1 


chemical products 
0.48 
0.45 
1 

petroleum products 
0.23 
0.25 
0.70 
1 
According to the above table, there are positive and negative correlations between returns on the studied induces, except for a few in which coefficients are close to zero. Therefore, these coefficients cannot be neglected. With the assumption of a correlation between industries, the portfolio VaR will be obtained from the following equation:
(22)
The nonlinear programming method was used in LINGO to obtain the weights of optimal portfolios and their VaR in each of the time horizons. Tables 15 and 16 show the values of the optimal portfolio and VaR.
Table 15. Optimal regime portfolio for indices of the designated industries with a VaR of 95%
investment 
metal products 
chemical products 
petroleum products 
Min VaR 







7 
0.30 
0.14 
0.45 
0.001 
1.57 
0.0001 
14 
0.26 
0.14 
0.50 
0.00 
1.17 
0.023 
21 
0.34 
0.059 
0.46 
0.017 
1.10 
0.062 
28 
0.45 
0.00 
0.32 
0.188 
1.087 
0.0064 
35 
0.41 
0.024 
0.37 
0.00 
1.02 
0.003 
Table 16. Optimal nonregime portfolio for indices of the designated industries with a VaR of 95%
time horizon 
investment 
metal products 
chemical products 
petroleum products 
Min VaR 






7 
0.31 
0.016 
0.46 
0.10 
1.23 
0.001 
14 
0.19 
0.15 
0.40 
0.02 
0.95 
0.004 
21 
0.24 
0.12 
0.28 
0.039 
1.040 
0.004 
28 
0.30 
0.00 
0.32 
0.19 
1.033 
0.0007 
35 
0.28 
0.067 
0.31 
0.024 
0.953 
0.001 
According to the above tables, the results indicate a changing trend in the optimal weights of each of the six industries in the investment portfolio within the 7–35week time horizon. Hence, it can be concluded that the optimal weights of the industries decreased in this period if their VaR increased. In the optimal portfolio, the highest weight belonged to the stocks which had highly expected returns and the lowest VaR of all the indices among the designated industries. Also, it can be concluded that the values of optimal weights of optimal portfolios for each of these industries differed in two regimes and nonregime states in each time horizon.
Portfolio Performance Evaluation
The sliding window approach was employed for each week in the posttest analysis of this study. The returntorisk ratio was used to show the superiority of the optimal portfolio with return fluctuations calculated through switching effects over the optimal portfolio with return fluctuations determined without regime effects. As expected, the modeled approach yielded more appropriate conditions than the values obtained from the ratio. According to the research findings and a comparison drawn between the resultant VaR determined by considering the switching regime effects and disregarding regime effects for the calculation of the entire portfolio risk, it can be stated that the VaR obtained from MRS–EGARCHt was superior in the optimal portfolio selection. Table 17 shows the results.
Table 17. Comparison between regime and nonregime optimal portfolios in the returntorisk ratio
Optimal nonregime portfolio 
Optimal nonregime portfolio 
time horizon 
0.00006 
0.001 
7 
0.019 
0.004 
14 
0.056 
0.003 
21 
0.0058 
0.00069 
28 
0.002 
0.001 
35 
Discussion and Conclusion
In this study, MRSGARCH (1,1), MRSIGARCH(1,1), MRSEGARCH(1,1), MRSFIGARCH(1,d,1), MRSFIEGARCH (1,d, 1) models were employed to estimate VaR and stock returns in each of the designated industries of oil products, investment, metal products, and chemical products. After that, the investment portfolio optimization problem was solved through the portfolio VaR minimization approach. According to the results, MRS FIEGARCH was not selected as the optimal model for any of the designated industries to measure fluctuations in stock returns. This finding is consistent with the results reported by Almasi et al. (2017), whereas it is inconsistent with the results reported by Fakhafi et al. (2016) who employed FIEGARCH and showed that negative news had greater impacts on conventional banks than Islamic banks and that negative shocks persisted longer in conventional banks. In contrast with the results reported by Bidgoli et al. (2013), FIEGARCH model with the skewed tstudent distribution outperformed the other parametric models in VaR prediction.
In consistence with the results reported by Kaporal and Zekich (2018), Alamooti et al. (2018), Maleki and Rabey (2018), Zolfaghari and Baghihian (2018), Bensada (2018), Ra’ee et al. (2014), Almasi et al. (2018), Zolfaghari and Sahabi (2017), Rostami et al. (2018), and Sanzo (2018), the results showed that only chemical products and investment industries followed the regime transition function. Hence, based on calculation results and the optimal MRS–EGARCHt model, higher weights of a portfolio belong to the industries with lower fluctuations in their stock returns (in other words, they have lower VaR). Moreover, the optimal shares of industries declined in the investment portfolio when returns fluctuations were higher, and vice versa. According to the results, it is recommended to invest in the industries with higher stability in stock prices and lower fluctuations in stock returns over time to create an optimal portfolio. This recommendation is consistent with the aim of the investment portfolio optimization problem, which is to minimize the investment portfolio risk for specific returns. It also indicates the high accuracy of the proposed model in VaR estimation. Finally, it is recommended to use other longterm memory models of the GARCH family such as FITGARCH and FIAPARCH in future studies to enhance the efficiency of the designed process and model the index risk of industries by considering the effects of macroeconomic variables on the risk of a portfolio consisting of stock indices of industries. Furthermore, a wide range of industries should be employed to measure VaR for portfolio optimization. It is also recommended to use the stocks of companies classified as subordinates to chemical industries and metal products to measure VaR for portfolio optimization.
Funding: This research received no external funding.
[1] JarqueBera
[2]generalized error distribution