Analysis of Nonstationary Time Series: Monte Carlo ...
Transcript of Analysis of Nonstationary Time Series: Monte Carlo ...
![Page 1: Analysis of Nonstationary Time Series: Monte Carlo ...](https://reader031.fdocuments.net/reader031/viewer/2022013018/61d0ce879289802a3c5c3eae/html5/thumbnails/1.jpg)
Analysis of Nonstationary Time Series:
Monte Carlo simulations on spurious regression
Kaiji Motegi∗
3rd Quarter 2019, Kobe University
1 Description
In this note, we run Monte Carlo simulations in order to better understand spurious regression. Let
ϵyt, ϵxti.i.d.∼ N(0, 1). Consider four cases of data generating processes (DGPs):
Case 1. {yt} follows random walk (RW) yt = yt−1 + ϵyt and {xt} follows RW xt = xt−1 + ϵxt.
Case 2. {yt} follows RW yt = yt−1 + ϵyt and {xt} follows random walk with drift (RW-D) xt =
0.2 + xt−1 + ϵxt.
Case 3. {yt} follows RW-D yt = 0.1 + yt−1 + ϵyt and {xt} follows RW xt = xt−1 + ϵxt.
Case 4. {yt} follows RW-D yt = 0.1 + yt−1 + ϵyt and {xt} follows RW-D xt = 0.2 + xt−1 + ϵxt.
For each case we draw J = 5000 Monte Carlo samples with sample size n ∈ {100, 500, 1000}. For each
Monte Carlo sample, we run a regression model yt = α+ βxt + ut and compute ordinary least squares(OLS) estimator β̂, t-statistic t̂β , and R2.
In Figures 1-4, we draw histograms of β̂, t̂β , and R2 over J = 5000 Monte Carlo samples. Somequantities diverge or converge as n → ∞, and others neither diverge nor converge.
In Figures 5-8, histograms of properly scaled β̂, t̂β , and R2 are plotted.
∗Tenure-track associate professor, Graduate School of Economics, Kobe University.E-mail: [email protected] Website: http://www2.kobe-u.ac.jp/˜motegi/
1
![Page 2: Analysis of Nonstationary Time Series: Monte Carlo ...](https://reader031.fdocuments.net/reader031/viewer/2022013018/61d0ce879289802a3c5c3eae/html5/thumbnails/2.jpg)
Figure 1: Histograms in Case 1 ({yt} is RW and {xt} is RW)
β̂ (n = 100) β̂ (n = 500) β̂ (n = 1000)
t̂β (n = 100) t̂β (n = 500) t̂β (n = 1000)
R2 (n = 100) R2 (n = 500) R2 (n = 1000)
We simulate J = 5000 Monte Carlo samples from random walk yt = yt−1 + ϵyt and random walk xt =
xt−1+ ϵxt, where ϵyt, ϵxti.i.d.∼ N(0, 1). Sample size is n ∈ {100, 500, 1000}. For each Monte Carlo sample,
we run a regression model yt = α + βxt + ut and compute OLS estimator β̂, t-statistic t̂β , and R2. Thisfigure presents histograms of each of those quantities over J = 5000 Monte Carlo samples.
2
![Page 3: Analysis of Nonstationary Time Series: Monte Carlo ...](https://reader031.fdocuments.net/reader031/viewer/2022013018/61d0ce879289802a3c5c3eae/html5/thumbnails/3.jpg)
Figure 2: Histograms in Case 2 ({yt} is RW and {xt} is RW-D)
β̂ (n = 100) β̂ (n = 500) β̂ (n = 1000)
t̂β (n = 100) t̂β (n = 500) t̂β (n = 1000)
R2 (n = 100) R2 (n = 500) R2 (n = 1000)
We simulate J = 5000 Monte Carlo samples from random walk yt = yt−1 + ϵyt and random walk with drift
xt = 0.2 + xt−1 + ϵxt, where ϵyt, ϵxti.i.d.∼ N(0, 1). Sample size is n ∈ {100, 500, 1000}. For each Monte
Carlo sample, we run a regression model yt = α+βxt+ut and compute OLS estimator β̂, t-statistic t̂β , andR2. This figure presents histograms of each of those quantities over J = 5000 Monte Carlo samples.
3
![Page 4: Analysis of Nonstationary Time Series: Monte Carlo ...](https://reader031.fdocuments.net/reader031/viewer/2022013018/61d0ce879289802a3c5c3eae/html5/thumbnails/4.jpg)
Figure 3: Histograms in Case 3 ({yt} is RW-D and {xt} is RW)
β̂ (n = 100) β̂ (n = 500) β̂ (n = 1000)
t̂β (n = 100) t̂β (n = 500) t̂β (n = 1000)
R2 (n = 100) R2 (n = 500) R2 (n = 1000)
We simulate J = 5000 Monte Carlo samples from random walk with drift yt = 0.1+ yt−1+ ϵyt and random
walk xt = xt−1 + ϵxt, where ϵyt, ϵxti.i.d.∼ N(0, 1). Sample size is n ∈ {100, 500, 1000}. For each Monte
Carlo sample, we run a regression model yt = α+βxt+ut and compute OLS estimator β̂, t-statistic t̂β , andR2. This figure presents histograms of each of those quantities over J = 5000 Monte Carlo samples.
4
![Page 5: Analysis of Nonstationary Time Series: Monte Carlo ...](https://reader031.fdocuments.net/reader031/viewer/2022013018/61d0ce879289802a3c5c3eae/html5/thumbnails/5.jpg)
Figure 4: Histograms in Case 4 ({yt} is RW-D and {xt} is RW-D)
β̂ (n = 100) β̂ (n = 500) β̂ (n = 1000)
t̂β (n = 100) t̂β (n = 500) t̂β (n = 1000)
R2 (n = 100) R2 (n = 500) R2 (n = 1000)
We simulate J = 5000 Monte Carlo samples from random walk with drift yt = 0.1+ yt−1+ ϵyt and random
walk with drift xt = 0.2 + xt−1 + ϵxt, where ϵyt, ϵxti.i.d.∼ N(0, 1). Sample size is n ∈ {100, 500, 1000}.
For each Monte Carlo sample, we run a regression model yt = α+ βxt + ut and compute OLS estimator β̂,t-statistic t̂β , and R2. This figure presents histograms of each of those quantities over J = 5000 Monte Carlosamples.
5
![Page 6: Analysis of Nonstationary Time Series: Monte Carlo ...](https://reader031.fdocuments.net/reader031/viewer/2022013018/61d0ce879289802a3c5c3eae/html5/thumbnails/6.jpg)
Figure 5: Histograms of scaled quantities in Case 1 ({yt} is RW and {xt} is RW)
β̂ (n = 100) β̂ (n = 500) β̂ (n = 1000)
n−1/2t̂β (n = 100) n−1/2t̂β (n = 500) n−1/2t̂β (n = 1000)
R2 (n = 100) R2 (n = 500) R2 (n = 1000)
We simulate J = 5000 Monte Carlo samples from random walk yt = yt−1 + ϵyt and random walk xt =
xt−1+ ϵxt, where ϵyt, ϵxti.i.d.∼ N(0, 1). Sample size is n ∈ {100, 500, 1000}. For each Monte Carlo sample,
we run a regression model yt = α + βxt + ut and compute OLS estimator β̂, t-statistic t̂β , and R2. Thisfigure presents histograms of each of those quantities scaled properly over J = 5000 Monte Carlo samples.
6
![Page 7: Analysis of Nonstationary Time Series: Monte Carlo ...](https://reader031.fdocuments.net/reader031/viewer/2022013018/61d0ce879289802a3c5c3eae/html5/thumbnails/7.jpg)
Figure 6: Histograms of scaled quantities in Case 2 ({yt} is RW and {xt} is RW-D)
n1/2β̂ (n = 100) n1/2β̂ (n = 500) n1/2β̂ (n = 1000)
n−1/2t̂β (n = 100) n−1/2t̂β (n = 500) n−1/2t̂β (n = 1000)
R2 (n = 100) R2 (n = 500) R2 (n = 1000)
We simulate J = 5000 Monte Carlo samples from random walk yt = yt−1 + ϵyt and random walk with drift
xt = 0.2 + xt−1 + ϵxt, where ϵyt, ϵxti.i.d.∼ N(0, 1). Sample size is n ∈ {100, 500, 1000}. For each Monte
Carlo sample, we run a regression model yt = α+βxt+ut and compute OLS estimator β̂, t-statistic t̂β , andR2. This figure presents histograms of each of those quantities scaled properly over J = 5000 Monte Carlosamples.
7
![Page 8: Analysis of Nonstationary Time Series: Monte Carlo ...](https://reader031.fdocuments.net/reader031/viewer/2022013018/61d0ce879289802a3c5c3eae/html5/thumbnails/8.jpg)
Figure 7: Histograms of scaled quantities in Case 3 ({yt} is RW-D and {xt} is RW)
n−1/2β̂ (n = 100) n−1/2β̂ (n = 500) n−1/2β̂ (n = 1000)
n−1/2t̂β (n = 100) n−1/2t̂β (n = 500) n−1/2t̂β (n = 1000)
R2 (n = 100) R2 (n = 500) R2 (n = 1000)
We simulate J = 5000 Monte Carlo samples from random walk with drift yt = 0.1+ yt−1+ ϵyt and random
walk xt = xt−1 + ϵxt, where ϵyt, ϵxti.i.d.∼ N(0, 1). Sample size is n ∈ {100, 500, 1000}. For each Monte
Carlo sample, we run a regression model yt = α+βxt+ut and compute OLS estimator β̂, t-statistic t̂β , andR2. This figure presents histograms of each of those quantities scaled properly over J = 5000 Monte Carlosamples.
8
![Page 9: Analysis of Nonstationary Time Series: Monte Carlo ...](https://reader031.fdocuments.net/reader031/viewer/2022013018/61d0ce879289802a3c5c3eae/html5/thumbnails/9.jpg)
Figure 8: Histograms of scaled quantities in Case 4 ({yt} is RW-D and {xt} is RW-D)
n1/2(β̂ − 0.5) (n = 100) n1/2(β̂ − 0.5) (n = 500) n1/2(β̂ − 0.5) (n = 1000)
n−1t̂β (n = 100) n−1t̂β (n = 500) n−1t̂β (n = 1000)
n(1−R2) (n = 100) n(1−R2) (n = 500) n(1−R2) (n = 1000)
We simulate J = 5000 Monte Carlo samples from random walk with drift yt = 0.1+ yt−1+ ϵyt and random
walk with drift xt = 0.2 + xt−1 + ϵxt, where ϵyt, ϵxti.i.d.∼ N(0, 1). Sample size is n ∈ {100, 500, 1000}.
For each Monte Carlo sample, we run a regression model yt = α + βxt + ut and compute OLS estimatorβ̂, t-statistic t̂β , and R2. This figure presents histograms of each of those quantities scaled properly overJ = 5000 Monte Carlo samples.
9