【发布时间】:2020-10-28 04:55:36
【问题描述】:
我正在尝试使用 ARIMA 对时间序列进行建模。我的数据框中有两列:monthlydate 和 sells。
time sell
1/31/2014 273033
2/29/2014 203019
3/31/2014 225844
4/30/2014 236374
5/31/2014 189666
6/30/2014 242742
7/31/2014 191682
8/31/2014 208270
9/30/2014 236533
10/31/2014 188010
11/30/2014 245185
12/31/2014 224990
1/31/2015 186733
2/28/2015 296641
3/31/2015 234317
4/30/2015 160818
5/31/2015 214937
6/30/2015 226710
7/31/2015 176030
8/31/2015 160991
9/30/2015 205668
10/31/2015 183680
11/30/2015 194428
12/31/2015 643302
1/31/2016 1306566
2/28/2016 2031110
3/31/2016 1756328
4/30/2016 1703885
5/31/2016 1620547
6/30/2016 1862650
7/31/2016 1742188
8/31/2016 1441375
9/30/2016 1666798
10/31/2016 1992165
11/30/2016 1965643
12/31/2016 1315753
1/31/2017 1676141
2/28/2017 1572417
3/31/2017 1442843
4/30/2017 1337359
5/31/2017 1350256
6/30/2017 1090291
7/31/2017 1329138
8/31/2017 1245024
9/30/2017 1246177
10/31/2017 1361814
11/30/2017 1574517
12/31/2017 1035892
1/31/2018 1358912
2/29/2018 1408371
3/31/2018 1239371
4/30/2018 874519
5/31/2018 1025873
在运行 ARIMA 模型之前,我需要弄清楚像 ARIMA(p,d,q) 这样的参数需要三个参数,并且传统上是手动配置的。
我开始在 python 中绘制ACF 和PACF 绘图,这是输出。我不明白它表示什么以及我们如何使用这个图来构建ARIMA 模型?
Autoregression Intuition Consider a time series that was generated by an autoregression (AR) process with a lag of k.
We know that the ACF describes the autocorrelation between an observation and another observation at a prior time step that includes direct and indirect dependence information.
This means we would expect the ACF for the AR(k) time series to be strong to a lag of k and the inertia of that relationship would carry on to subsequent lag values, trailing off at some point as the effect was weakened.
We know that the PACF only describes the direct relationship between an observation and its lag. This would suggest that there would be no correlation for lag values beyond k.
很难理解。能用通俗的语言解释吗?
如何解释以上情节? 如何使用python找到最优的p,d,f参数?
【问题讨论】:
标签: python-3.x time-series arima