BookmarkSubscribeRSS Feed
Lakey91
Calcite | Level 5

Hi

I am in the process of automating ARIMA (with forecasts) for 290 employment series.

Two questions:

1) Is there a way to get ARIMA to choose an ARIMA optimal model (ie, which AR and MA terms to include) for each (perhaps based on minimising AIC)? Particularly, when including multiple AR and MA terms (eg AR(1,2) and MA(2,6,8))?

2) If not, we plan to use a general ARIMA model that seems to work quite well across all series. The issue is, occasionally this gives rise to a model which is 'non-invertible'. Is there a way of measuring/identifying non-invertible models (perhaps by a statistic of some sort produced in the output) such that SAS can know to seperate these variables? Basically, I want sas to run the standard ARIMA process on all series, and for those series that are deemed non-invertible, spit them into a seperate data set (to be dealt with seperately).

Any assistance would be greatly appreciated.

@sas

3 REPLIES 3
udo_sas
SAS Employee

Hello -

"1) Is there a way to get ARIMA to choose an ARIMA optimal model (ie, which AR and MA terms to include) for each (perhaps based on minimising AIC)? Particularly, when including multiple AR and MA terms (eg AR(1,2) and MA(2,6,8))?"

Yes, HPFDIAGNOSE (part of SAS Forecast Server) provides such feature. Details can be found here: http://support.sas.com/documentation/cdl/en/hpfug/65566/HTML/default/viewer.htm#hpfug_hpfdiag_toc.ht...

"2) If not, we plan to use a general ARIMA model that seems to work quite well across all series. The issue is, occasionally this gives rise to a model which is 'non-invertible'. Is there a way of measuring/identifying non-invertible models (perhaps by a statistic of some sort produced in the output) such that SAS can know to seperate these variables? Basically, I want sas to run the standard ARIMA process on all series, and for those series that are deemed non-invertible, spit them into a seperate data set (to be dealt with seperately)."

Did you consider using the Time Series Forecasting System of SAS/ETS instead of using one ARIMA specification for all models? Given the number of series you are facing, this seems to be a good choice.

See: http://support.sas.com/documentation/cdl/en/etsug/65545/HTML/default/viewer.htm#pt04.htm for details.

Thanks,

Udo

Lakey91
Calcite | Level 5

Is there a statistic or something that is produced in the output that reflects non invertibility? Eg - greater than 1, indicates it is non invertible?

Does HPFDIAGNOSE need an advanced version of SAS? If so, is there any way of doing an ARIMA optimisation with just base SAS?

udo_sas
SAS Employee

Hello -

Invertibility

To obtain a non-explosive ARIMA model for forecasting, the AR and MA parameter estimates must lie within the stationarity and invertibility regions in order to have a stable model.  One of the criteria for termination is when one or more of the parameter estimates tries to iterate outside of the stationarity or invertibility boundary.  (The stationarity bound is for AR parameters and the invertibility bound is for MA parameters). These boundary conditions vary depending on the specified model. If the invertibility or stationarity bounds are violated, then the iterations terminate. For a model to be considered stable, the invertibility and stationarity bounds must be satisfied.  If any of these conditions are not satisfied then the model is considered to be unstable.

The following excerpt is taken from the Details section called, "Stationarity and Invertibility", in the PROC ARIMA documentation:

============================================================================

Stationarity and Invertibility

By default PROC ARIMA requires that the parameter estimates for the AR and MA parts of the model always remain in the stationary and invertible regions, respectively. The NOSTABLE option removes this restriction and for high-order models may save some computer time. Note that using the NOSTABLE option does not necessarily result in an unstable model being fit, since the estimates may leave the stable region for some iterations, but still ultimately converge to stable values.

============================================================================

You might want to try adding the NOSTABLE option to the ESTIMATE statement to see if allowing the procedure to iterate outside of the invertibility and stationarity bounds will allow the model to converge to a solution.  However, please note that the parameter estimates may not iterate back into the the boundaries, which would then lead to an explosive or unstable model.

HPFDIAGNOSE

HPFDIAGNOSE is only available with SAS Forecast Server - while it is certainly possible to do an ARIMA optimization with just SAS/ETS it will require a lot of coding and experience. As I mentioned earlier, you might be better off with a "fix model repository" approach like TSFS is using. So instead of "optimizing" models on the fly, have a fixed list of predefined models and do run a "horse-race" between them, with other words: pick the model which is most appropriate for the data at hand, potentially using a holdout sample.

Thanks,

Udo

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 3 replies
  • 1846 views
  • 0 likes
  • 2 in conversation