I followed the tutorial to study the SARIMAX model: https://www.digitalocean.com/community/tutorials/a-guide-to-time-series-forecasting-with-arima-in-python-3. The date range of data is 1958-2001.
mod = sm.tsa.statespace.SARIMAX(y,
order=(1, 1, 1),
seasonal_order=(1, 1, 1, 12),
enforce_stationarity=False,
enforce_invertibility=False)
results = mod.fit()
when are fitting an ARIMA Time Series Model, I found the author all date range data to fit parameter of model. But when validating Forecasts, the author used date started from 1998-01-01 as one part of date range of data for fitting model.
pred = results.get_prediction(start=pd.to_datetime('1998-01-01'), dynamic=False)
I know in machine learning model, the training data and validation(test) data is different, I mean different range. I mean the author is right? why do like this(I mean the reason touse all train data), I a new one to SARIMAX model.
Could you guys tell me more about this model, for example how about predict days or weeks not just month, I mean how to set the parameter of order=(1,1,1), seasonal_order=(1, 1, 1, 12). Thanks!