我需要从sktime
包中适配ARIMA模型。我想从sktime.forecasting.model_selection
中使用SlidingWindowSplitter
,但我真的不明白它是如何工作的。如果我想要匹配一个简单的ARIMA,我会这样做
...
model = ARIMA(order = (p, d, q)).fit(y_train)
y_pred, y_conf = model.predict(fh, return_pred_int=True)
但是SlidingWindowSplitter是如何工作的呢?
应该可以:
from sktime.forecasting.all import *
from sktime.forecasting.model_evaluation import evaluate
y = load_airline()
forecaster = ARIMA()
cv = SlidingWindowSplitter()
out = evaluate(forecaster, cv, y)