AIC and BIC vs ACF and PACF
In this exercise you will apply an AIC-BIC order search for the earthquakes time series. In the last lesson you decided that this dataset looked like an AR(1) process. You will do a grid search over parameters to see if you get the same results. The ACF and PACF plots for this dataset are shown below.
<\center>\center>The ARIMA model class and the time series DataFrame earthquake are available in your environment.
Diese Übung ist Teil des Kurses
ARIMA Models in Python
Anleitung zur Übung
- Loop over orders of
pandqbetween 0 and 2. - Inside the loop
tryto fit an ARMA(p,q) toearthquakeon each loop. - Print
pandqalongside AIC and BIC in each loop. - If the model fitting procedure fails print
p,q,None,None.
Interaktive Übung
Vervollständige den Beispielcode, um diese Übung erfolgreich abzuschließen.
# Loop over p values from 0-2
for p in ____:
# Loop over q values from 0-2
for q in ____:
try:
# create and fit ARMA(p,q) model
model = ____
results = model.____
# Print order and results
print(p, q, ____, ____)
except:
print(p, q, ____, ____)