We’ve seen that the autoregressive operator ϕ(B)is extremely useful for determining stationarity. In this section, we will explore another useful application of ϕ(B), namely converting a finite AR model into a so called MA(∞) consisting of an infinite series of noise (or shock) terms. This in turn will help us understand the autocovariance of AR processes and derive confidence intervals for predictions.
How might we go about finding weights, call them ψj’s with associated operator ψ(B), for higher order AR(p) processes? In other words, we want to find ψ weights to satisfy the equation
Given that the left-hand side of Eq. (4) does not have any backshifted terms, we conclude that the coefficients of each backshift operator must be zero, i.e.
Fortunately, statsmodels performs the operations in Eq. (5) for us using the property impulse_response[4]. Continuing with the example from above, add the following line to the code:
Brockwell & Davis (1991) chapter 3.3 provides three broad methods to calculate the theoretical autocovariance and autocorrelation of AR models (and ARMA models in general). We will focus on the first here.
The first method relies on representing the model in the form of Eq. (2). γ(h) is then calculated in the same fashion as Eq. (5)
where we have used the fact that the noise is iid resulting in zero covariance for different noise terms. Unfortunately, AR(p) models with p≥2 do not have the same convenient geometric series representation seen with an AR(1) model. Nevertheless, Eq. (6) provides an elegant method for calculating the autocovariance, and hence the autocorrelation, of any stationary AR process—or, as we shall see, any stationary ARMA process. The fact that the ψ weights decay exponentially results in it being possible to truncate Eq. (6) after say, thirty terms, with relatively little loss in accuracy.
The second and third methods in Brockwell & Davis (1991) rely on using recursion relations relating higher h values to lower ones. We will not go into great depth regarding this method, but it is instructive to see how it might be applied to an AR(2) model. Let us begin with the AR(2) process xt=ϕ1xt−1+ϕ2xt−2+wt. We can multiply through by xt−h and take the expectation:
Without additional information, we cannot further simplify in Eq. (9). However, dividing through by γ(0) generates a recursion relation for the autocorrelation
Brockwell, P. J., & Davis, R. A. (1991). Time Series: Theory and Methods. In Springer Series in Statistics. Springer New York. 10.1007/978-1-4419-0320-4