識別 II
你已經知道 savings 這個時間序列在不做差分的情況下就是定態的。現在有了這項資訊,你可以嘗試判斷哪一個模型階數最適合。
plot_acf() 與 plot_pacf() 函式都已匯入,時間序列也已載入到 DataFrame savings 中。
本練習屬於課程
Python 中的 ARIMA 模型
練習說明
- 在座標軸
ax1上繪製 ACF,落後期數設定為 1–10。 - 對 PACF 做同樣的圖。
動手互動練習
試著完成這個範例程式碼,體驗一下這個練習。
# Create figure
fig, (ax1, ax2) = plt.subplots(2,1, figsize=(12,8))
# Plot the ACF of savings on ax1
____
# Plot the PACF of savings on ax2
____
plt.show()