Time Series Analysis

Chapter 1 · Stochastic Processes and Stationarity

The slide of the lecture is on the left, the same figure or table on the right, computed in the browser from the same data. The ▶ button moves the parameter step by step; the “Worked example” boxes redo the calculation with the numbers of the chapter.

Time series and stochastic processes · Stationarity · White noise and the random walk · The lag operator, differencing and the Wold decomposition · Sample ACF and PACF · Portmanteau tests: Box–Pierce and Ljung–Box · Transformations · Two classic series

Time series and stochastic processes

Four series of this course

Slide 5: Four series of this course
Slide 5
    Question for the room The ▶ button moves a 5-year window from 1995–1999 to 2021–2025. Which of the four series has a mean close to the same value in every window?
    Answer

    The BET returns: the mean is 0.18% in 2000–2004, −0.05% in 2008–2012, 0.03% in 2013–2017 and 0.07% in 2021–2025, all close to 0. The standard deviation changes, however: 1.48%, 2.04%, 0.78% and 0.88%. The mean of real GDP rises from 21.3 bn EUR in 1995–1999 to 48.1 bn EUR in 2021–2025, and the mean of inflation falls from 59.3% in 1995–1999 to 0.82% in 2013–2017: for these series the mean depends on the period.

    An ensemble of paths

    Slide 9: An ensemble of paths
    Slide 9
      Question for the room The ▶ button moves the date t of the cross-section from 2 to 100 (φ = 0.7). How does the spread of the 40 values at date t change, on the left and on the right?
      Answer

      On the left it stays the same: Var(Xt) = 1/(1 − φ²) = 1.96 at every t, and the variance of the 40 values fluctuates around it with no trend (1.17 at t = 10, 2.44 at t = 50, 2.04 at t = 100): the process is stationary. On the right it grows with t: for the random walk Var(Xt) = t, the band ±1.96√t goes from ±6.20 at t = 10 to ±19.60 at t = 100, and the variance of the 40 values rises from 14.94 to 116.93. With a larger φ the band on the left widens (±13.89 at φ = 0.99), but it stays the same at every t.

      Stationarity

      Weakly but not strictly stationary

      Slide 16: Weakly but not strictly stationary
      Slide 16
        Question for the room The ▶ button raises k, the degrees of freedom of the χ² at odd t, from 1 to 60. What changes: the mean and the variance, or the shape of the distribution?
        Answer

        Only the shape. For every k, (χ²k − k)/√(2k) has mean 0 and variance 1, so the process stays weakly stationary. The theoretical skewness √(8/k) falls from 2.83 at k = 1 to 1.26 at k = 5 and 0.37 at k = 60 (in the sample: 2.80, 1.30, 0.35). P(Xt < −1.6) at odd t is 0 up to k = 5 and 4.2% at k = 60, against 5.9% at even t. For every finite k, the distributions at even and odd t differ, so the process is not strictly stationary.

        Properties of the autocovariance function

        Slide 18: Properties of the autocovariance function
        Slide 18

        Worked example

        \[\begin{gathered}\mathrm{Var}\Big(\sum_{i=1}^{3}a_iX_i\Big)=\sum_{i,j}a_ia_j\gamma(i-j)\\ =\gamma(0)\big[(a_1^2+a_2^2+a_3^2)+2(a_1a_2+a_2a_3)\rho(1)+2a_1a_3\rho(2)\big]\ge 0\end{gathered}\]
            Question for the room With ρ(1) = 0.9, the ▶ button raises ρ(2) from −1 to 1. From which value of ρ(2) is the pair (ρ(1), ρ(2)) an ACF? Is the vector a = (1, −1, 1) enough to decide?
            Answer

            From ρ(2) = 2 × 0.9² − 1 = 0.62. With a = (1, −1, 1) the variance is γ(0)(3 − 4ρ(1) + 2ρ(2)): −2.4γ(0) at ρ(2) = −0.9 and 0 at ρ(2) = 0.30. Between 0.30 and 0.62 this vector shows no contradiction, but the smallest eigenvalue of the autocorrelation matrix is still negative (−0.13 at ρ(2) = 0.30, −0.01 at 0.60): another vector a gives a negative variance. With a = (1, −1, −1) instead, and ρ(1) = 0.9, ρ(2) = −0.9, the variance is 4.8γ(0) > 0, so the contradiction appears only with the vector (1, −1, 1).

            Worked example: a moving average of order 1

            Slide 19: Worked example: a moving average of order 1
            Slide 19

            Worked example

            \[X_t=\varepsilon_t+\theta\varepsilon_{t-1}:\quad \gamma(0)=\sigma^2(1+\theta^2),\quad \gamma(1)=\theta\sigma^2,\quad \rho(1)=\frac{\theta}{1+\theta^2},\quad \gamma(h)=0\ \ (|h|\ge 2)\]
                Question for the room The ▶ button moves θ from −2 to 2. Is there another θ, besides 0.6, with ρ(1) = 0.441?
                Answer

                Yes: θ = 1/0.6 = 1.67, because θ/(1 + θ²) does not change when θ is replaced by 1/θ; on the slider, θ = 1.65 gives ρ(1) = 0.443 and θ = 1.70 gives 0.437. The two processes have the same ACF but a different γ(0): 1.36 at θ = 0.6 and 3.72 at θ = 1.65 (σ² = 1). ρ(1) alone does not identify θ; |ρ(1)| reaches its maximum 0.5 at θ = 1.

                Worked example: an autoregression of order 1

                Slide 20: Worked example: an autoregression of order 1
                Slide 20

                Worked example

                \[\begin{gathered}X_t=\phi X_{t-1}+\varepsilon_t:\quad \gamma(0)=\frac{\sigma^2}{1-\phi^2},\quad \rho(h)=\phi^{|h|},\\ X_t=\sum_{j\ge 0}\phi^j\varepsilon_{t-j},\quad \psi_j=\phi^j,\quad \sum_{j\ge0}\psi_j^2=\frac{1}{1-\phi^2}\end{gathered}\]
                    Question for the room The ▶ button raises φ from 0 to 0.99. What share of Σψj2 do the first 11 Wold weights (j = 0, …, 10) give?
                    Answer

                    A smaller and smaller share: 99.3% at φ = 0.8, 67.6% at φ = 0.95 and 19.8% at φ = 0.99, because the share is 1 − φ22. The sum itself, γ(0)/σ² = 1/(1 − φ²), rises from 2.78 to 10.26 and 50.25, and a shock loses half of its effect after 3.1, 13.5 and 69.0 periods. The closer φ is to 1, the more the distant shocks matter.

                    Question for the room: which series are stationary?

                    Slide 21: Question for the room: which series are stationary?
                    Slide 21
                      Question for the room Which of conditions (ii) and (iii) of weak stationarity fails for series B, C and D?
                      Answer

                      Only series A is stationary. B has the deterministic trend μt = 0.04t: condition (ii) fails, and the mean is 2.84 in the first half and 9.05 in the second. C has a standard deviation 7.5 times larger at the end than at the start (1.09 and 2.74 over the two halves): condition (iii) fails at h = 0. D has a level shift of +4 at t = 150, which moves the mean from −0.07 to 4.19: condition (ii). The ▶ button runs a rolling window of 50 observations over the series: for A the window mean stays between −0.13 and 0.39 (windows ending at t = 49, 149, 199 and 299), for B it rises from 0.95 to 11.10, for C the standard deviation grows from 0.67 to 3.70, and for D the mean jumps from 0.19 (t = 100–149) to 3.99 (t = 150–199).

                      White noise and the random walk

                      Three kinds of white noise

                      Slide 25: Three kinds of white noise
                      Slide 25
                        Question for the room The ▶ button raises the number of observations T from 100 to 1000 (α = 0.1). What happens to the Ljung–Box statistic Q*(10) of the squares for the three series?
                        Answer

                        For the GARCH it grows with T: 17.8 (p = 0.059) at T = 100, 42.5 at T = 500 and 73.2 at T = 1000 (p < 0.001); from T = 150 on the test rejects at every step. For the i.i.d. noises the statistic does not grow with T: it stays between 2.0 and 21.4 for the Gaussian series and between 3.2 and 8.0 for the Laplace series. The Gaussian series nevertheless rejects at T = 150 and 200 (p = 0.039 and 0.018): a false rejection, which happens in about 5% of the samples. The GARCH squares are correlated although the series stays uncorrelated; with T = 1000, Q*(10) is 9.3 at α = 0 and 838.9 at α = 0.14.

                        Random walks and their variance

                        Slide 28: Random walks and their variance
                        Slide 28

                        Worked example

                        \[X_t=\sum_{i=1}^{t}\varepsilon_i,\quad \mathrm{Var}(X_t)=t\sigma^2,\quad \mathrm{Cov}(X_t,X_s)=\min(t,s)\,\sigma^2,\quad \rho(X_t,X_s)=\sqrt{t/s}\ \ (t\le s)\]
                            Question for the room The ▶ button moves the date t from 10 to 250. Does the correlation between Xt and Xt+10 depend only on the distance of 10 periods?
                            Answer

                            No. Over the 5000 paths, the correlation is 0.708 between X10 and X20 and 0.954 between X100 and X110, like the theoretical values √(t/s) = 0.707 and 0.953. For a stationary process the correlation would depend only on the lag. The variance also grows with t: 10.1 at t = 10, 98.1 at t = 100 and 249.1 at t = 250 (theoretical tσ²).

                            Question for the room: which one is real?

                            Slide 32: Question for the room: which one is real?
                            Slide 32
                              Question for the room One panel is the log price of the BET over its last 500 trading days, the other five are random walks with the same drift and the same daily standard deviation. Which panel is the BET?
                              Answer

                              Series D: the BET, 11 September 2024 – 18 September 2026. By eye it cannot be told apart from the random walks. Its daily changes set it apart: ρ̂(1) = 0.123, and the p-value of the Ljung–Box test Q*(10) is 0.018, the only one below 5% among the six series; for the simulated random walks the p-values lie between 0.377 and 0.911.

                              The lag operator, differencing and the Wold decomposition

                              Differencing

                              Slide 36: Differencing
                              Slide 36

                              Worked example

                              \[\begin{gathered}\Delta X_t=X_t-X_{t-1},\quad \Delta^2X_t=X_t-2X_{t-1}+X_{t-2},\\ \Delta_sX_t=X_t-X_{t-s},\quad 100\,\Delta\ln Y_t\approx 100\Big(\frac{Y_t}{Y_{t-1}}-1\Big)\end{gathered}\]
                                  Question for the room Select real GDP and the quarter 2020Q2. What does the quarterly growth rate show, and what does the annual one show?
                                  Answer

                                  The quarterly growth rate is positive, 7.76% (log) and 8.07% (simple), because the not seasonally adjusted GDP of the second quarter is always above that of the first. The annual growth rate, 100 Δ4 ln Yt = −9.87%, compares the quarter with the same quarter of 2019 and shows the pandemic fall. On not seasonally adjusted data, Δ mixes the season with the economy, and Δ4 separates them.

                                  S&P 500: the level and its difference

                                  Slide 37: S&P 500: the level and its difference
                                  Slide 37
                                    Question for the room The bottom panel shows the returns, Δ ln Pt. What ρ̂(1) does the second difference, Δ² ln Pt, have?
                                    Answer

                                    −0.543. The returns are already close to white noise (ρ̂(1) = −0.099), and the difference of white noise is an MA(1) with ρ(1) = −0.5: one more difference creates negative autocorrelation and raises the standard deviation from 1.21% to 1.80%. The level ln Pt has an ACF of 0.999 at lag 1 and 0.973 at lag 50; at lag 1 the ACF stays above 0.99 for every start of the sample between 2000 and 2024.

                                    Wold weights of four processes

                                    Slide 40: Wold weights of four processes
                                    Slide 40
                                      Question for the room The ▶ button raises φ in the first panel from 0 to 1; the second panel gets −φ and the third θ = φ. What happens to Σψj²?
                                      Answer

                                      It rises: Σψj² = 1/(1 − φ²) is 1 at φ = 0, 2.78 at φ = 0.8 and 10.26 at φ = 0.95, where ψ10 = 0.599. At φ = 1, ψj = 1 for every j, as for the random walk (the dots in the last panel reach the bars), and the sum is infinite: the process no longer has a Wold form and is no longer stationary. The second panel, with −φ, has the same sum, because ψj² = φ2j; for the MA(1), Σψj² = 1 + θ² stays at most 2.

                                      Time averages: ergodic and non-ergodic

                                      Slide 43: Time averages: ergodic and non-ergodic
                                      Slide 43
                                        Question for the room The ▶ button extends the horizon T of the averages from 10 to 2000. What does X̄T approach on each path, on the left and on the right?
                                        Answer

                                        On the left, μ = 0 on every path: X̄T lies between −1.95 and 0.77 at T = 10, between −0.33 and 0.63 at T = 100 and between −0.13 and 0.09 at T = 2000; the AR(1) is ergodic for the mean. On the right, each average approaches its own Z: at T = 2000 the averages lie between −0.95 and 1.16, like the drawn values of Z (between −0.99 and 1.15), and the spread does not shrink with T. With φ closer to 1, convergence on the left is slower: the standard deviation of X̄2000 is about 1/((1 − φ)√T), that is 0.075 at φ = 0.7 and 2.24 at φ = 0.99.

                                        Sample ACF and PACF

                                        Sample autocovariance and autocorrelation

                                        Slide 46: Sample autocovariance and autocorrelation
                                        Slide 46

                                        Worked example

                                        \[\begin{gathered}\bar x=\frac1T\sum_{t=1}^{T}x_t,\quad \hat\gamma(k)=\frac1T\sum_{t=1}^{T-k}(x_t-\bar x)(x_{t+k}-\bar x),\\ \hat\rho(k)=\frac{\hat\gamma(k)}{\hat\gamma(0)},\quad \pm\frac{1.96}{\sqrt T}\end{gathered}\]
                                            Question for the room With the data of the slide, the ▶ button moves the lag k from 1 to 4. At which lag is |ρ̂(k)| largest, and is it significant?
                                            Answer

                                            At k = 3 and k = 4: ρ̂(3) = −0.20 and ρ̂(4) = −0.40, against ρ̂(1) = 0.10 and ρ̂(2) = 0.00. ρ̂(4) comes from a single product, (−2) × 2 = −4, divided by T = 5, and stays inside the band ±0.88. With T = 5 no autocorrelation can be separated from noise; this is why we use h ≤ T/4.

                                            Confidence bands for the sample ACF

                                            Slide 47: Confidence bands for the sample ACF
                                            Slide 47

                                            Worked example

                                            \[\pm\frac{1.96}{\sqrt T}\ \ (\text{i.i.d.}),\qquad \pm 1.96\sqrt{\frac{1}{T}\Big(1+2\sum_{k=1}^{h-1}\hat\rho(k)^2\Big)}\ \ (\text{Bartlett, MA}(h-1))\]
                                                Question for the room Select the quarterly GDP growth (T = 125) and the lag h = 8. How wide is the Bartlett band compared with ±1.96/√T?
                                                Answer

                                                Twice as wide: ±0.361 against ±0.175, because ρ̂(1), …, ρ̂(7) of this seasonal series are large (Σρ̂(k)² = 1.62). ρ̂(8) = 0.93 stays outside both bands. Of 20 lags, all 20 bars fall outside ±1.96/√T and 10 outside the Bartlett band. For the BET returns, the Bartlett band at h = 5 is ±0.0243, almost the same as ±0.0240: there the two bands give the same answer.

                                                Sampling distribution of the sample ACF

                                                Slide 48: Sampling distribution of the sample ACF
                                                Slide 48
                                                  Question for the room The ▶ button raises the number of lags m from 1 to 20, on the same 10000 samples of white noise. How often is at least one bar outside the band?
                                                  Answer

                                                  More and more often: in 4.5% of the samples at m = 1, 20.3% at m = 5 and 50.3% at m = 20, although there is no correlation at all. With independent tests it would be 1 − 0.95m: 5.0%, 22.6% and 64.2%; at large lags Var(ρ̂(h)) < 1/T, so slightly fewer bars fall outside. At m = 20, on average 0.73 bars fall outside. On the left, the samples with at least one bar outside the band (red) often have ρ̂(1) close to 0: the alarm comes from the other lags.

                                                  Theoretical and sample ACF of four processes

                                                  Slide 50: Theoretical and sample ACF of four processes
                                                  Slide 50
                                                    Question for the room The ▶ button raises T from 50 to 500. What happens to the sample ACF of the random walk at lag 10?
                                                    Answer

                                                    It rises: ρ̂(10) is −0.08 at T = 50, 0.37 at T = 100 and 0.55 at T = 500. The random walk has no theoretical ACF, and the decay of its sample ACF depends on the length of the sample. For the AR(1) with φ = 0.8, ρ̂(10) approaches the theoretical value 0.11: −0.14 at T = 50, 0.11 at T = 100 and 0.09 at T = 500, while the band narrows from ±0.277 to ±0.088.

                                                    ACF and PACF of three processes

                                                    Slide 53: ACF and PACF of three processes
                                                    Slide 53
                                                      Question for the room The ▶ button moves the last coefficient of each process from −0.4 to 0.45: φ of the AR(1), φ₂ of the AR(2) (φ₁ = 0.5) and θ of the MA(1). Which value does the sample PACF of the AR(2) at lag 2 follow?
                                                      Answer

                                                      The coefficient φ₂: φ̂22 = −0.40 for φ₂ = −0.4, −0.03 for φ₂ = 0 and 0.38 for φ₂ = 0.45 (in theory, φ22 = φ₂). φ̂33 stays inside the band (0.05, 0.04, −0.01): the PACF cuts off after lag 2. ρ̂(2) does not follow φ₂: at φ₂ = 0 it is 0.28, close to ρ(2) = φ₁² = 0.25. At the same time φ̂11 of the AR(1) follows φ (−0.38 at φ = −0.4 and 0.48 at φ = 0.45), and ρ̂(1) of the MA(1) follows θ/(1 + θ²) (−0.30 and 0.37; in theory −0.345 and 0.374).

                                                      BET: ACF of returns, absolute and squared returns

                                                      Slide 56: BET: ACF of returns, absolute and squared returns
                                                      Slide 56
                                                        Question for the room Select the S&P 500. Do its returns have the same first-order autocorrelation as the BET? And their squares?
                                                        Answer

                                                        For the returns, no: ρ̂(1) = −0.099 for the S&P 500 and 0.109 for the BET (0.170 for EUR/RON). For the squares, yes: ρ̂(1) = 0.31 for the S&P 500 and 0.33 for the BET, with Q*(10) = 6133 and 2440. The sign of the autocorrelation of returns differs from one market to another, while volatility clustering appears in all three. If the BET sample starts in 2013, ρ̂(1) falls to 0.054 for the returns and to 0.18 for the squares.

                                                        Portmanteau tests: Box–Pierce and Ljung–Box

                                                        Worked example: the Ljung–Box statistic

                                                        Slide 60: Worked example: the Ljung–Box statistic
                                                        Slide 60

                                                        Worked example

                                                        \[Q(m)=T\sum_{h=1}^{m}\hat\rho(h)^2,\qquad Q^*(m)=T(T+2)\sum_{h=1}^{m}\frac{\hat\rho(h)^2}{T-h}\ \sim\ \chi^2(m)\ \text{under }H_0\]
                                                            Question for the room With the numbers of the slide, how does the p-value of the Ljung–Box test change from m = 1 to m = 3?
                                                            Answer

                                                            It rises: 0.011 at m = 1 (Q*(1) = 6.44), 0.019 at m = 2 (Q*(2) = 7.94) and 0.035 at m = 3 (Q*(3) = 8.61). The statistic grows a little, because ρ̂(2) and ρ̂(3) are small, while the critical value gains one degree of freedom at each lag: too large an m dilutes the evidence. Box–Pierce gives Q(3) = 8.33, with p = 0.040.

                                                            Box–Pierce and Ljung–Box in small samples

                                                            Slide 61: Box–Pierce and Ljung–Box in small samples
                                                            Slide 61
                                                              Question for the room With T = 50, the ▶ button raises m from 1 to 20. How do the two tests move away from the 5% level?
                                                              Answer

                                                              In opposite directions. Box–Pierce rejects the true hypothesis in 4.5% of the samples at m = 1, in 4.0% at m = 10 and in 2.4% at m = 20; Ljung–Box in 5.2%, 7.4% and 9.4%. With T = 500 and m = 20 the rates are 5.0% and 5.9%. This is why we keep m well below T (for example, m ≤ T/5).

                                                              Ljung–Box statistics of real series

                                                              Slide 63: Ljung–Box statistics of real series
                                                              Slide 63
                                                                Question for the room If the sample starts in 2025 (about 425 days), does the Ljung–Box test with m = 10 still reject white noise for the BET returns?
                                                                Answer

                                                                No: Q*(10) = 14.3, p = 0.161, below the critical value 18.31. On the full sample, with 6670 days, Q*(10) = 108.0, p < 0.001. The small autocorrelation of the BET returns (ρ̂(1) = 0.11) needs many observations to be separated from noise; the non-rejection does not show that the series is white noise. The squares reject on the short sample too: Q*(10) = 68.6 for the BET and 103.0 for the S&P 500.

                                                                Interpreting the Ljung–Box statistics

                                                                Slide 64: Interpreting the Ljung–Box statistics
                                                                Slide 64
                                                                  Question for the room The ▶ button raises m from 1 to 30. For which series is the evidence weakest at m = 1, and what happens at m = 4?
                                                                  Answer

                                                                  The quarterly GDP growth: Q*(1) = 7.7, p = 0.006, only 2.0 times the critical value 3.84. At m = 4, Q*(4) = 168.1 against 9.49, because ρ̂(4) = 0.96: the season. All 10 series reject white noise for every m between 1 and 30; at m = 10 the smallest ratio belongs to the annual GDP growth, 4.1.

                                                                  Transformations

                                                                  Romanian real GDP: log, quarterly and annual growth

                                                                  Slide 67: Romanian real GDP: log, quarterly and annual growth
                                                                  Slide 67
                                                                    Question for the room The ▶ button raises the lag k of the difference on the right from 1 to 8. For which k does the seasonal spike of the ACF at lag 4 disappear?
                                                                    Answer

                                                                    For k = 4: ρ̂(4) = 0.03. For k = 1, 2, 3 and 5, ρ̂(4) stays between 0.94 and 0.96: a difference that does not cover a whole year keeps the season. k = 8 removes the season too, but ρ̂(4) = 0.52, because two two-year growth rates one year apart share a year. The annual growth rate, k = 4, has a mean of 2.73% and ρ̂(1) = 0.63.

                                                                    The Box–Cox transformation

                                                                    Slide 69: The Box–Cox transformation
                                                                    Slide 69

                                                                    Worked example

                                                                    \[w=\frac{y^\lambda-1}{\lambda}\ (\lambda\ne0),\quad w=\ln y\ (\lambda=0),\quad y=(\lambda w+1)^{1/\lambda},\quad \mathrm{CV}\Big(\frac{\mathrm{sd}_i}{\mathrm{mean}_i^{\,1-\lambda}}\Big)\to\min_\lambda\]
                                                                        Question for the room Select real GDP. Is the logarithm still the choice of Guerrero's criterion?
                                                                        Answer

                                                                        No: for real GDP, λ̂ = 0.39, with criterion 0.110, against 0.165 at λ = 0 and 0.218 at λ = 1. For nominal GDP, λ̂ = 0.02 and the criterion is 0.243 both at λ̂ and at λ = 0, so we choose the logarithm. The value of λ̂ depends on the series; for the HICP index, λ̂ = 0.87.

                                                                        Box–Cox for Romanian nominal GDP

                                                                        Slide 70: Box–Cox for Romanian nominal GDP
                                                                        Slide 70
                                                                          Question for the room With λ = 1 (no transformation), how many times larger is the seasonal amplitude in the last five years than in the first five?
                                                                          Answer

                                                                          10.5 times: 3059 million EUR in the first five years and 32155 in the last five, because the seasonal swing is a stable share of the level. With λ = 0, the logarithm, the ratio is 1.07 (0.392 and 0.420), and Guerrero's criterion, 0.243, is practically the minimum reached at λ̂ = 0.02; at λ = 1 the criterion is 0.677.

                                                                          Over-differencing

                                                                          Slide 72: Over-differencing
                                                                          Slide 72
                                                                            Question for the room The ▶ button raises φ of the differenced series from 0 (white noise) to 1 (random walk). How does ρ̂(1) of the first difference change?
                                                                            Answer

                                                                            It rises from −0.54 towards 0: −0.28 at φ = 0.5, −0.10 at φ = 0.9 and −0.06 at φ = 1, in line with the theoretical value −(1 − φ)/2. Differencing is appropriate only for the random walk, where ΔXt = εt; for a stationary series, a negative ρ̂(1) close to −0.5 signals over-differencing. The variance of the first difference falls from 2.01 to 0.95.

                                                                            Two classic series

                                                                            The Nile and the sunspots: series and ACF

                                                                            Slide 77: The Nile and the sunspots: series and ACF
                                                                            Slide 77
                                                                              Question for the room The ▶ button moves the year of the break from 1875 to 1965; the mean up to the break and the mean after it are removed from the Nile flow and from the sunspots. What happens to ρ̂(1) of the Nile after removing the two means?
                                                                              Answer

                                                                              It is smallest around 1898: 0.13 for a break after 1897 and 0.16 after 1898, with Q*(10) = 13.0 (p = 0.225). With the break after 1880 or after 1920, ρ̂(1) is 0.40 and 0.42, and after 1950 it is 0.50, the value of the flow itself. A large part of the autocorrelation of the flow comes from the change in the mean around 1898. For the sunspots the same operation hardly changes the ACF: with the break after 1898, ρ̂(1) = 0.81 (0.82 before) and the peak at lag 10 is 0.64 (0.66 before), because their autocorrelation comes from the cycle of about 11 years, not from a break.

                                                                              Simulations: shocks drawn with the seeds of the chapter code; when the parameters differ from those of the lecture, the series is recomputed from the same shocks or simulated in the browser. Real and nominal GDP: Eurostat, quarterly, not seasonally adjusted, in the version used in the lecture. HICP: Eurostat, up to August 2026. EUR/RON: BNR reference rate. BET and S&P 500: the course market data (EODHD), up to 18 September 2026. The Nile and the sunspots: the statsmodels data sets.