Type:
Solution Manual
Resource:
Analysis of Financial Time Series
Edition:
3rd Edition
Author(s):
Ruey S. Tsay
Solutions to Exercises of Chapter 1 Problem 1: Summary statistics of daily returns from January 1999 to December 2008. Stock
mean
St. Dev. Skew Ex. Kurt. Min. Max. t-ratio(p-value) (a) Percentage simple returns: 2515 data points AXP 0.015 2.446 -0.035 6.048 −17.595 17.927 0.299(0.77) CAT 0.060 2.170 0.012 4.453 −14.518 14.723 1.375(0.17) SBUX 0.048 2.683 −0.082 8.746 −28.286 14.635 0.898(0.37) (b) Percentage log returns: 2515 data points AXP −0.015 2.453 −0.336 6.486 −19.352 16.489 −0.316(0.75) CAT 0.036 2.171 −0.202 4.695 −15.686 13.735 0.830(0.41) SBUX 0.012 2.696 −0.597 12.90 −33.249 13.659 0.221(0.83) The sample means of the log returns are not significantly different from zero at the 5% level. Problem 2: Summary statistics of monthly returns from 1975 to 2008. Stock
mean
St. Dev. Skew Ex. Kurt. Min. Max. t-ratio(p-value) (a) Percentage simple returns: 408 data points GM 0.557 9.273 −0.383 2.048 −38.931 27.662 1.213(0.23) VW 1.012 4.507 −0.743 2.666 −22.536 14.160 4.534(0.00) EW 1.331 5.596 −0.300 4.334 −27.225 29.926 4.806(0.00) SP 0.730 4.360 −0.571 2.269 −21.763 13.177 3.382(0.00) (b) Percentage log returns: 408 data points GM 0.110 9.950 −1.024 4.021 −49.317 24.422 0.232(0.82) VW 0.905 4.561 −1.051 3.938 −25.536 13.243 4.006(0.00) EW 1.167 5.626 −0.836 5.242 −31.779 26.179 4.190(0.00) SP 0.632 4.402 −0.855 3.335 −24.543 12.378 2.900(0.00) The sample mean of the monthly GM stock return is not significantly different from zero, but those of the monthly log returns of indices are all significantly different from zero at the 5% level. Problem 3: Focus on monthly S&P composite log returns. • Average annual return = sample mean * 12 = (sum of log returns)/(number of years) = 7.583%. P • V = exp(0.07583 ∗ (2008 − 1975 + 1)) ≈ $13.17. (or V = exp( 408 t=1 rt ), where rt is the monthly log return). 3
4 Problem 4: Daily log returns of American Express stock from 1999 to 2008. p • Skewness: test-statistic is t = −0.336/ 6/2515 = −6.888 with p value 5.66 × 10−12 . Thus, we reject the null hypothesis of no skewness at the 5% level. • Kurtosis: test-statistic is t = √ 6.486
24/2515
= 66.40, which is large and has a p value close to zero.
Thus, we reject the null hypothesis of zero excess kurtosis. That is, the distribution of the log returns has heavy tails.
Problem 5: Summary statistics for daily foreign exchange rates from January 4, 2000 to March 27, 2009. Currency CA EU JP UK
mean Variance Skew Ex. Kurt. Min. Percentage log returns: 2322 data points −0.0068 0.345 −0.239 8.245 −5.072 0.011 0.428 0.126 2.805 −3.003 −0.002 0.440 −0.671 4.581 −5.216 −0.006 0.382 −0.395 7.061 −4.966
Max. 3.807 4.621 2.708 4.435
The sample means of daily log returns of the exchange rates considered are small. The returns all have positive excess kurtosis, indicating heavy tails.
0.4 0.0
0.2
density
0.6
0.8
5
−2
0
2
4
log−return
Figure 1: Empirical density function of the daily log returns of USEU exchange rate: January 4, 2000 to March 27, 2009.
6
Solutions to Exercises of Chapter 2 1. From the model, R101 = a101 + 0.2a100 . Taking conditional expectation at t = 100, we have R100 (1) = 0.2a1000 = 0.2 × 0.01 = 0.002 The associated forecastp error is e100 (1) = R101 − R100 (1) = a101 . Therefore, the standard deviation of the forecast error is Var[e100 (1)] = std(a101 ) = 0.025. For 2-step ahead forecast, we have R102 = a102 + 0.2a101 ,
and R100 (2) = E(R102 |F100 ) = 0. The forecast error is e100 (2) = R102 − R100 (2) = a102 + 0.2a101 p p with standard deviation Var(a102 + 0.2a101 ) = 1.04σa2 = 0.0255. To compute ACF of Rt , use the model to obtain • Var(Rt ) = (1 + 0.22 )σa2 = 0.00065.
• Cov(Rt , Rt−1 ) = Cov(at + 0.2at−1 , at−1 + 0.2at−2 ) = Cov(0.2at−1 , at−1 ) = 0.2σa2 = 0.000125.
• Cov(Rt , Rt−ℓ ) = 0 for ℓ ≥ 2.
Therefore, ACF of Rt is ρ1 = 0.192, ρℓ = 0 for ℓ ≥ 2. 2. Taking expectation of the model, we have E(rt ) = 0.01 + 0.2E(rt−2 ). 0.01 = 0.0125. Taking variance of the model, we obtain Therefore, E(rt ) = 1−0.2
Var(rt ) = 0.04Var(rt−2 ) + σa2 . 0.02 Therefore, Var(rt ) = 1−0.96 = 0.0208. For autocorrelation function, we may drop the constant term and multiply the equation by rt−ℓ to obtain
rt rt−ℓ = 0.2rt−2 rt−ℓ + at rt−ℓ . Taking the expectation for ℓ > 0, we have γℓ = 0.2γℓ−2 , where γℓ is the lag-ℓ autocovariance of rt . Therefore, ρℓ = 0.2ρℓ−2 for ℓ > 0. Since ρ0 = 1, we have ρ2 = 0.2, ρ4 = 0.22 , · · · for even number ℓ. For ℓ = 1, we use ρℓ = ρ−ℓ to obtain ρ1 = 0.2ρ−1 = 0.2ρ1 . This implies 0.8ρ1 = 0. Therefore, ρℓ = 0 if ℓ is an odd number. 7
4
6
rate
8
10
8
1950
1960
1970
1980
1990
2000
2010
year
Figure 2: Time series plot for monthly US unemployment rate.
For 1-step ahead forecast at t = 100, we have r101 = 0.01 + 0.2r99 + a101 . Taking conditional expectation, r100 (1) = 0.01 + 0.2r99 = 0.01 + 0.2 × (0.02) = 0.014. √ The forecast error is e100 (1) = a101 with standard deviation 0.02 = 0.141. For 2-step ahead forecast, using r102 = 0.01 + 0.2r100 + a102 , we obtain r100 √ (2) = 0.01 + 0.2(−0.01) = 0.008. The associated forecast error is a102 with standard deviation 0.02 = 0.141. 3. Consider the monthly U.S. unemployment rate from January 1948 to March 2009. The data are seasonally adjusted and obtained from the Federal Reserve Bank at St Louis’ website: http://research.stlouisfed.org/fred/. Build a time series model for the series and use the model to forecast the unemployment rate for April, May, June and July 2009. In addition, compute the average period of business cycles if they exist? [Note that there are more than one model fits the data well. You only need an adequate model.] Explanatory Analysis of the Series The first thing one should do is an exploratory analysis of the series to try and figure out what the data looks like. Let Xt be the series of monthly unemployment rate, in percentages. Figure 2 shows that there seems to be some sort of cycle, since every so often there are peaks, although they do not seem to occur at “regular” intervals. This may be an indication of a business cycle or a combination of business cycles and seasonal effect (even though we are told the data has been seasonally adjusted.) Figure 3 shows the ACF and the PACF for Xt . On the ACF we see that the serial correlations
9
Partial ACF
0.4 0.0
ACF
0
5
10
15
20
25
−0.1 0.0 0.1 0.2 0.3
Series diff(rate)
0.8
Series rate
0
5
Lag
10
15
20
25
Lag
−0.2
0.2
ACF
0.6
1.0
Series diff(rate)
0
5
10
15
20
25
Lag
Figure 3: Autocorrelation function and partial autocorrelation function for monthly US unemployment rate.
decay slowly. This could be an indication that the series may not be stationary and, thus, a (regular) difference might be needed. The ACF and PACF of the differenced series (1 − B)Xt show two important characteristics. First, the differeced series appears to be stationary as the serial correlations are small in magnitude. Second, there are serial correlations at lags 12 and 24, indicating that some seasonality remains even though the data were seasonally adjusted. Fitting the Model If the command ar with maximum likelihood method is used, one identifies an AR(11) model for the series: (1 − 0.99B − 0.24B 2 + 0.07B 3 + 0.06B 4 − 0.03B 5 + 0.13B 6 + 0.04B 7 − 0.05B 8 + 9
0.01B + 0.13B
10
11
− 0.13B )(Xt − 5.66) = at
(1) (2)
iid
where at ∼ N (0, 0.0387). Several coefficients are not significant at the 5% level so that the model can be simplified. The resulting model is (1 − 0.98B − 0.17B 2 + 0.17B 6 + 0.12B 10 − 0.13B 11 )(Xt − 5.661) = at , iid
where at ∼ N (0, 0.039). The characeristic roots of the fitted model contain conjugate complex roots so that it indicates the existence of business cycles. Each pair of the complex roots provides a period of the cycle. For instance, the roots 0.721 ± 1.087i with modulous 1.305 give a period k = 2π/ cos−1 (0.721/1.305) = 6.38 months.
10
−8 −4 0
4
Standardized Residuals
0
200
400
600
Time
ACF
0.0 0.4 0.8
ACF of Residuals
0
5
10
15
20
25
Lag
0.4 0.0
p value
0.8
p values for Ljung−Box statistic
0
5
10
15
20
25
30
35
lag
Figure 4: Model chekcing of fitted AR(11) model for monthly US unemployment rate
Alternatively, to handle the serial correlations at seasonal lags, one can employ a multiplicative seasonal model. For simplicity, lower-order models are entertained and we obtain (1 − 0.58B − 0.24B 2 )(1 − 0.561B 12 )Xt = (1 − 0.581B)(1 − 0.819B 12 )at , where σa2 = 0.03725. Except for the seasonality, this multiplicative model does not contain business cycle. Residual Analysis An important part of model fitting is to check the assumptions that we made. Most of these can be done using the residuals of the models. We use the command tsdiag in R to check the two fitted models. the results are shown in Figures 4 and 5. From the plots, we see that residuals of the AR(11) model still have some minor serial correlations whereas those of the seasonal model appears to be adequate. Finally, using fitted models the forecasts of unemployment arte for April, May, June and July 2009 are > predict(m1,6) # AR(11) model $pred Time Series: Start = 736 End = 741 Frequency = 1 [1] 8.796765 8.981996 9.112555 9.246428 9.277609 9.276570
11
−8 −4 0
4
Standardized Residuals
0
200
400
600
Time
ACF
0.0 0.4 0.8
ACF of Residuals
0
5
10
15
20
25
Lag
0.4 0.0
p value
0.8
p values for Ljung−Box statistic
0
5
10
15
20
25
30
35
lag
Figure 5: model checking for a fittd ARIMA model
$se Time Series: Start = 736 End = 741 Frequency = 1 [1] 0.1975856 0.2767134 0.3556580 0.4358310 0.5206642 0.6121825 > predict(m2,6) # seasonal model $pred Time Series: Start = 736 End = 741 Frequency = 1 [1] 8.841844 9.017154 9.126917 9.231977 9.338707 9.439207 $se Time Series: Start = 736 End = 741 Frequency = 1 [1] 0.1930098 0.2728039 0.3632395 0.4508560 0.5384476 0.6247633
4. Consider the monthly simple returns of the Decile 1, Decile 2, Decile 9, and Decile 10 of NYSE/AMEX/NASDAQ based on market capitalization. The data span is from January 1970 to December 2008, and the data are obtained from CRSP.
12 • Test H0 : ρ1 = ρ2 = · · · = ρ12 = 0 versus Ha : ρi 6= 0 for some i ∈ {1, 2, . . . , 12}. Apply the Ljung-Box statistics. For Decile 2 returns, we have Q(12) = 11.88 with p value 0.46. For Decile 10 returns, we have Q(12) = 36.10 with p value 0.0003. Therefore, we reject H0 for Decile 10 returns, but cannot reject H0 for Decile 2 returns. > da=read.table("m-dec12910.txt",header=T) > d2=da$dec2 > d10=da$dec10 > Box.test(d2,lag=12,type=’Ljung’) Box-Ljung test data: d2 X-squared = 11.8766, df = 12, p-value = 0.4556 > Box.test(d10,lag=12,type=’Ljung’) Box-Ljung test data: d10 X-squared = 36.103, df = 12, p-value = 0.0003119
• The ACF of Decile 2 returns indicates some serial correlation at lag 1. See Figure 6. Therefore, an MA(1) or an AR(1) model is entertained. The fitted MA(1) model is rt = 0.0092 + (1 + 0.123B)at , where σa2 = 0.0023. Model checking of the fitted model is shown in Figure 7. From the plots, the fitted model is adequate. • The 1-step to 12-step ahead forecasts are give below: > predict(m1,12) $pred Time Series: Start = 469 End = 480 Frequency = 1 [1] 0.014015984 0.009192279 0.009192279 0.009192279 0.009192279 0.009192279 [7] 0.009192279 0.009192279 0.009192279 0.009192279 0.009192279 0.009192279 $se Time Series: Start = 469 End = 480 Frequency = 1 [1] 0.04829823 0.04867484 0.04867484 0.04867484 0.04867484 0.04867484 [7] 0.04867484 0.04867484 0.04867484 0.04867484 0.04867484 0.04867484
5. Consider the daily simple returns of IBM stock in the file d-ibm3dx7008.txt. Compute the first 100 lags of ACF of the absolute daily simple returns of IBM stock. Is there evidence of long-range dependence? Why? Figure 8 shows that sample ACF of the absolute simple returns of IBM stock. The ACFs are not large in magnitude, but decay slowly. These features indicate that there is long memory in the
13
0.0
0.2
0.4
ACF
0.6
0.8
1.0
Series d2
0
5
10
15
20
25
Lag
Figure 6: Autocorrelation function fo monthly Decile 2 returns
−4
0 2
Standardized Residuals
0
100
200
300
400
Time
ACF
0.0 0.4 0.8
ACF of Residuals
0
5
10
15
20
25
Lag
0.4 0.0
p value
0.8
p values for Ljung−Box statistic
2
4
6
8
10
12
lag
Figure 7: Model checking of MA(1) model for monthly Decile 2 returns
14 abs(ibm)
0.0
0.2
0.4
ACF
0.6
0.8
1.0
Series
0
20
40
60
80
100
Lag
Figure 8: Autocorrelation function of absolute returns of IBM stock.
absolute returns. 6. Consider the demand of electricity of a manufacturing sector in the US. The data are logged and denote the demand of a fixed day of each month in file ’power6.txt’. Build a time series model for the series and use the fitted model to produce 1 to 24-step ahead forecasts. Figure 6 presents the time series plot of the monthly log demand for electricity. We can see that there is a strong seasonal component as well as non-stationarity. This kind of series is a typical example in which the so-called airline model might work. After checking the ACF and PACF for the original series, as well as the series with one regular difference, one seasonal difference, and both, we conclude that both differences are needed. The fitted model is (1 − B)(1 − B 12 )Dt = (1 − 0.487B)(1 − 0.966B 12 )at iid
where at ∼ N (0, 3.337 × 10−4 ). > da=read.table("power6.txt",header=F) > pow=da[,1] > m1=arima(pow,order=c(0,1,1),seasonal=list(order=c(0,1,1),period=12)) > m1 Call: arima(x=pow,order=c(0,1,1),seasonal = list(order=c(0,1,1),period = 12)) Coefficients: ma1 -0.4865 s.e. 0.0631
sma1 -0.9664 0.1179
(3)
9.4
9.6
pow
9.8
10.0
15
0
50
100
150
200
250
Index
Figure 9: Time series plot for monthly log demand of electricity.
sigma^2 estimated as 0.0003337:
log likelihood = 633.59,
aic = -1261.17
> tsdiag(m1,gof=36) > predict(m1,24) $pred Time Series: Start = 265 End = 288 Frequency = 1 [1] 9.882315 9.867492 9.873761 9.892808 9.921631 10.006038 10.046234 [8] 10.063123 10.072570 10.006692 9.951904 9.928664 9.910806 9.895983 [15] 9.902252 9.921299 9.950123 10.034529 10.074725 10.091614 10.101061 [22] 10.035183 9.980395 9.957155 $se Time Series: Start = 265 End = 288 Frequency = 1 [1] 0.01845143 0.02073927 0.02279866 0.02468686 0.02644055 0.02808495 [7] 0.02963826 0.03111412 0.03252307 0.03387347 0.03517206 0.03642438 [13] 0.03789603 0.03918050 0.04042417 0.04163071 0.04280325 0.04394451 [19] 0.04505688 0.04614244 0.04720304 0.04824032 0.04925577 0.05025070
Both coefficients are significant. However, θ̂12 is very close to one, indicating that the seasonal
16
−3
−1
1 2
Standardized Residuals
0
50
100
150
200
250
Time
0.0 0.4 0.8
ACF
ACF of Residuals
0
5
10
15
20
Lag
0.4 0.0
p value
0.8
p values for Ljung−Box statistic
0
5
10
15
20
25
30
35
lag
Figure 10: Analysis of residuals for model (3).
pattern is stable. Figure 6 shows the analysis of the residuals for model (3). From there we see that the model seems to be appropiate. The Ljung-Box statistic for lag 24 is Q(24) = 24.9, which compared to a χ2 with 22 degrees of freedom gives a p value of 0.302. Thus, we do not have enough evidence to reject the null of no autocorrelation. We also observe constant variance, and most residuals within the confidence bands. Finally, the forecats using model (3) are shown in the above output. 7. Let rt be the “ew” return, in percentages, and Mt , Ut , Wt and Rt denote Monday, Tuesday, Wednesday and Thursday dummy variables. Analysis based on Splus (OLS command): (a) If linear regression is used, the model is rt = 0.224 − 0.317Mt − 0.198Ut − 0.102Wt − 0.103Rt + et , where all estimates are highly singificant with maximum p value 0.0008. If HAC is used (Newey-West method), the magnitudes of t-ratios of the coefficient estimate increase.Therefore, use of HAC estimator does not change the conclusion. The residuals of the model, however, has strong serial correlation. (b) If a regression model with time-series errors is used, the fitted model is (1−0.54B−0.32B 2 )(1+0.04B 5 )(rt −0.22+0.32Mt +0.20Ut +0.11Wt +0.10Rt ) = (1−0.43B−0.40B 2 )at , (4)
17
−10
0 5
15
Standardized Residuals
0
2000
4000
6000
Time
0.4 0.0
ACF
0.8
ACF of Residuals
0
10
20
30
Lag
0.4 0.0
p value
0.8
p values for Ljung−Box statistic
5
10
15
20
lag
Figure 11: Analysis of residuals for model (4).
where all estimates are significant at the 5% level and the variance of at is 0.6412. Model checking in Figure 7 indicates that there are some minor serial correlations at the higher order lags. For simplicity, we shall not consider those higher-order model. Thus, the weekday effects remain siginificant. 8. As demonstrated by the prior exercise, daily returns of equal-weighted index have some weekday effects. How about daily returns of the &P composite index? Let rt be the simple return of the S&P index, in percentages. Let the weekdays indicators be Mt , Ut , Wt , Rt , Ft , respectively. In what follows, we use all five indicators but require no constant term in the model. • The regression model is rt = −0.004Mt + 0.074Ut + 0.064Wt + 0.006Rt + 0.033Ft + et , where the standard error of et is 1.117. Among the weekday indicators, only Tuesday and Wednesday have significant coefficients at the 5% level. The t-ratios are 2.566 and 2.219, respectively. However, the residuals of the model have strong serial correlations because the series gives Q(12) = 67.02 with a p value 1.149 × 10−9 .
• A regression model with time-series errors is enterained and the fitted model is
(1−0.07B−0.31B 2 )(rt +0.004Mt −0.075Ut −0.063Wt −0.008Rt −0.032Ft ) = (1−0.09B−0.37B 2 )at ,
18 where several estimates ate not significant at the 5% level. A simplifed model becomes (1 − 0.38B 2 )(rt − 0.075Ut − 0.062Wt − 0.032Ft ) = (1 − 0.34B 2 )at , where the variance of at is 1.24. The Ljung-Box statistics of the residuals give Q(10) = 16.37 with a p value 0.09. Thus, the model seems adquate. The t-ratio for the Firday dummy is 0.032/0.029 = 1.10, which is smaller than the 95% critical value of 2. Thus, the effect of Friday is not significant at the 5% level. 9. Now, consider similar problems for individual stock returns. We use the daily simple returns of the IBM stock in this study. Let rt be the daily simple returns of IBM stock, in percentages. The same weekday indicators as those of Exercise 2.8. • The linear regression model is rt = 0.200Mt + 0.144Ut − 0.036Wt + 0.002Rt − 0.059Ft + et , where the standard error of et is 1.785. Based on the fitted regression model, only Monday and Tuesday have significant coefficients at the 5% level. The t-ratio for Friday dummy is −1.264 with a p value 0.21 so that there is no Friday effect on IBM simple daily returns.
• Ljung-Box statistics of the residuals give Q(12) = 16.84 with a p value 0.16 so that the residuals have no serial correlations. However, ACF of the residuals shows a minor lag-1 serial correlations. • The fitted regression model with time-series errors is rt − 0.20Mt − 0.14Ut + 0.04Wt − 0.002Rt + 0.059Ft + (1 − 0.032B)at ,
where the variance of at is 3.179. The Ljung-Box statistics of the residuals give Q(12) = 9.42 with a p value 0.67. Therefore, the model is adequate in capturing the serial correlations in the series. 10. Consider the weekly yields of Moody’s AAA & BAA seasoned bonds from January 5, 1962 to April 10, 2009. The data are obtained from Federal Reserve Bank at St Louis. Weekly yields are averages of daily yields. Obtain the summary statistics (sample mean, standard deviation, skewness, excess kurtosis, minimum and maximum) of the two yield series. Are the bond yields skewed? Do they have heavy tails? Answer the questions using 5% significance level. The sample size is 2467. Table 1 gives the summary statistics for both time series. The standard errors for the skewness and kurtosis are computed under the normality assumption. Thus, Var(Ŝ(x)) = 6/T , and Var(K̂(x)) = 24/T . For the Aaa bond yield, we have that Ŝ 0.857 t(S) = p = = 17.38, 6/2467 6/T
19 Table 1: Summary statistics for weekly yields of Moody’s AAA & BBB seasoned bonds from January 5, 1962 to April 10, 2009.
Aaa Baa
X̄
σ̂
Ŝ(x)
K̂(x)
Min
Max
7.83 8.85
2.419 2.717
0.857 0.930
0.578 0.761
4.19 4.78
15.85 17.29
which gives a p value close zero. Hence, we reject the null hypothesis of no skewness. Similarly, K̂ − 3 0.579 = 5.866, t(K) = p = 24/2467 24/T
with a p value of 0.01. Thus, we also reject the null hypothesis of no excess kurtosis. In particular, to test for heavy tails we need a one sided test. The p value for that is 0.01/2 = 0.005. Therefore, the bond yield does have heavy tails. A similar analysis can be done for the Baa bond yield. We have t(S) = 18.86, and t(K) = 7.72. Both t-statistics have a p value of zero. Therefore, we reject that the yield is not skewed, and also we conclude that it has heavy tails. 11. Consider the weekly Aaa bond yield. Build a time series model for the series. Figure 11 shows the time plot of the Aaa bond yields. The series is not stationary. ACF of the bond yields shows stron serial correlations so that we examine the differenced series (1 − B)Yt , where Yt is the weekly Aaa bond yield. The ar command identifies an AR(9) for (1 − B)Yt . Thus, one can employ and ARIMA(9,1,0) model. The fitted model is (1−0.37B +0.06B 2 −0.08B 3 −0.01B 4 −0.04B 5 +0.03B 6 +0.05B 7 −0.03B 8 +0.06B 9 )(1−B)Yt = at , where the variance of at is 0.00793. Several coefficient estimates are not significant at the 5% level. Alternatively, one can use ARIMA models. To keep the model simple, we focus on lower-order models and obtain (1 − 1.44B + 0.67B 2 )(1 − B)Yt = (1 − 1.061B + 0.213B 2 + 0.223B 3 )at , where the variance of at is 0.00798. All coefficient estimates are significant at the 5% level. The Ljung-Box statistics of the residuals give Q(10) = 11.89 with a p value 0.29. Thus the model appears to be adquate. 12. Again, consider the two bond yield series. What is the relationship between the two series? To answer this question, build a time series model using yields of Aaa bond as the dependent variable and yields of Baa bond as the independent variable.
4
6
8
Aaa 10
12
14
16
20
0
500
1000
1500
2000
2500
time
Figure 12: Time series plot of Aaa bond yields from January 5, 1962, to April 10, 2009
Define yt = (1 − B)Yt and xt = (1 − B)Xt , where Yt and Xt are the weekly yields of Aaa and Baa bonds. The difference is taken as the individual yield series contains a unit root. [Note that a proper way to analyze the data is to model the two series jointly; see the chapter on vector time series.] We start the analysis with the model yt = βxt + et . The fitted model is yt = 0.946xt + et . The estimate is highly significant. However,the residuals show certain serial correlations. Based on the ACF and PACF of the residuals, we specify the model (1 − 0.25B + 0.02B 2 − 0.04B 3 + 0.07B 4 )(yt − 0.948xt ) = at , where the residual variance is 0.00267. The Ljung-Box statistics of the residuals give Q(12) = 24.87 with a p value 0.02. The model needs further improvement. 13. Denote the monthly equal-weighted return by rt . Model specification: • t-ratio of the sample mean = 4.04, indicating the need of a constant term.
• PACF suggests an AR(1) model • ACF suggests an MA(1) model Estimation of AR(1) model shows
(1 − 0.227B)(rt − 1.063) = at ,
σa = 5.45
21 where standard errors of the coefficients are 0.046 and 0.260, respectively. Residual Q-statistic gives Q(12) = 13.68 with a p value 0.32. Thus, there is no significant serial correlations at the 5% level for lags 1 to 12. For MA(1) model, we have rt = 1.061 + at + 0.239at−1 ,
σa = 5.44
where standard errors of the coefficients are 0.316 and 0.045. Residual Q-statistic gives Q(12) = 11.62, which is also insignificant at the 5% level. The two models are adequate. Forecasts (standard errors) at the time point t = 456 are time 457 458
AR(1) 2.601 (5.448) 1.411 (5.586)
MA(1) 2.250 (5.439) 1.061 (5.592)
Model comparison: Express the AR(1) model as (1 − 0.227B)rt = 0.826 + at . Using long-division, we have rt = 1.069 + at + 0.227at−1 + 0.052at−2 + 0.012at−3 + 0.003at−4 + · · · which is very close to the MA(1) model. Thus, the two models are essentially equivalent. 14. Due the small magnitude of the data, I use percentage returns, i.e. yt = 100(ft − ft−1 ) and xt = 100(st − st−1 ). The correlation between yt and xt is 0.389. Thus, I start with the simple linear regression model yt = βxt + et . The fitted model is yt = 0.621xt + et . The residuals, however, show strong serial dependence, e.g. Q(10) = 115.0. I then use EACF to identify an ARMA model for the residual and it suggests clearly an ARMA(1,1) model. Consequently, the model becomes yt = 0.723 +
1 − 0.936B at 1 − 0.820B
where all estimates are highly significant and σa = 0.029. The residual series has no significant serial correlations because Q(10) = 5.5, which is low. Note that if one employs autoregressive models only, then he needs a high order model; see Chapter 8 where an AR(8) model is used. This appears to be an excellent example for demonstration the usefulness of using ARMA models. Also, the residuals appear to be heteroscedastic. One can further refine the model by using the models discussed in Chapter 3. 15. Let yt be the logarithm of the GDP deflator. The ACF and PACF of (1 − B)yt suggests an ARMA model. The fitted model is (1 − 0.877B − 0.011B 2 )(xt − 0.0086) = (1 − 0.338B)at ,
22 where σa2 = 1.76 × 10−5 and xt = (1 − B)yt , where yt is the logarithm of the GDP deflator. The AR(2) coefficient is insiginificant. In addition, residual ACF shows some serial correlation at lag 7. Therefore, we refine the model as (1 − 1.245B + 0.27B 2 )(xt − 0.0084) = (1 − 0.69B)(1 − 0.30B 7 )at , where the variance of at is 1.66 × 10−5 . All estimates, except the AR(2), are significant at the 5% level. The t-ratio for the AR(2) coefficient is −1.69. Model checking of the fitted model is shown in Figure 15 and the model appears to be adequate. Finally, the prediction of the model are 4.819, 4.825, 4.830 and 4.836, respectively. These predictions care obtained as below: > predict(m1,4) $pred Time Series: Start = 248 End = 251 Frequency = 1 [1] 0.004792946 0.005783540 0.005385856 0.005764302 $se Time Series: Start = 248 End = 251 Frequency = 1 [1] 0.004073850 0.004661837 0.004969789 0.005200728 > y[length(y)] [1] 4.814166 > mp=predict(m1,4) > names(mp) [1] "pred" "se" > Y=y[length(y)]+mp$pred[1] > Y [1] 4.818959 > Y1=Y+mp$pred[2] > Y1 [1] 4.824743 > y2=Y1+mp$pred[3] > y2 [1] 4.830128 > y3=y2+mp$pred[4] > y3 [1] 4.835893
23
−4
0 2 4
Standardized Residuals
0
50
100
150
200
250
Time
0.0 0.4 0.8
ACF
ACF of Residuals
0
5
10
15
20
Lag
0.4 0.0
p value
0.8
p values for Ljung−Box statistic
5
10
15
20
lag
Figure 13: Model checking for the fitted model of Exercise 2.15
24