Exercise

Equivalence of AR(1) and MA(infinity)

To better understand the relationship between MA models and AR models, you will demonstrate that an AR(1) model is equivalent to an MA(\(\small \infty\)) model with the appropriate parameters.

You will simulate an MA model with parameters \(\small 0.8, 0.8^2, 0.8^3, \ldots \) for a large number (30) lags and show that it has the same Autocorrelation Function as an AR(1) model with \(\small \phi=0.8\).

Note, to raise a number x to the power of an exponent n, use the format x**n.

Instructions

100 XP
  • Import the modules for simulating data and plotting the ACF from statsmodels
  • Use a list comprehension to build a list with exponentially decaying MA parameters: \(\small 1, 0.8, 0.8^2, 0.8^3, \ldots\)
  • Simulate 5000 observations of the MA(30) model
  • Plot the ACF of the simulated series