Turn on suggestions

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

- Home
- /
- Analytics
- /
- Forecasting
- /
- Time series with a state with less than 24 months of history

Options

- RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page

🔒 This topic is **solved** and **locked**.
Need further help from the community? Please
sign in and ask a **new** question.

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

Posted 02-08-2016 01:36 PM
(1516 views)

I have a hierarchical time series (using SAS Forecast studio for desktop). Total-->Region and each region is made out of states. For one state i have history less than 24 months ( i have 13 but the first couple of months not very reliable info) what are some suggestions as to how to handle this?

1 ACCEPTED SOLUTION

Accepted Solutions

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

proc similarity also supports time warping so that series with different length can be compared. you probably dont need the use the time warping functionality, just compute the similary using the common months across all states. Please check the doc to see how to disable time warping in proc similarity.

once similar state(s) are found, you first take the simple average of similar states by each year/month. Then you compare the difference between the state averages with the state with short history using the months when data is available in all states. For example, the state average/state with short histoty is 1.5. You then copy the state averages for the missing months and adjust the averages down by a factor of 1.5. you can make the adjustment factor by month as well.

7 REPLIES 7

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

I can think of 2 approaches:

1. "Making the history". Basically copy the data of the current year to last year so that the hierarchical aggregation won't be affected by the missing historical data. You can make some trend adjustment while copying the data by looking at the trend from other states. You can also try to run a regression model on all states or just the states within a region to predict/impute the missing history,

2. "Leave it out". If the data for a state is short and not reliable, leave it out so that you can get the best possible forecasts for other states. You can then some similarity analysis between the state in question and other states to find a similar states using the existing 13+ month data. You can use PROC SIMILARITY (SAS/ETS) to measure the similarities between time series. Once you have identified the similar states, you can average out the forecasts by each period and then adjust the level based on the 13+ month of data. Basically you are borrowing the shape of the forecasts from similar states and adjust the forecast level based on the state's own data.

Hope this helps

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

You are right for both questions. Since forecast studio license includes SAS/ETS, you should be able to access PROC SIMILARITY via a regular SAS session. Also the each state should be a column in the input data for PROC SIMILARITY.

here is an example from the proc documentation:

This simple example illustrates how to compare two time sequences using similarity analysis. The following statements create an example data set that contains two time sequences of differing lengths.

data test; input i y x; datalines; 1 2 3 2 4 5 3 6 3 4 7 3 5 3 3 6 8 6 7 9 3 8 3 8 9 10 . 10 11 . ; run;

The following statements perform similarity analysis on the example data set:

ods graphics on; proc similarity data=test out=_null_ print=all plot=all; input x; target y / measure=absdev; run;

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

So i transposed my data and i have the following columns:

date, State1,....state28

For all states except state 28 i have 36 obs for state 28 i have 15 obs, but i have the last 15 observations so i am missing the history.

Do i run the proc similarity as is on this datatset?

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

proc similarity also supports time warping so that series with different length can be compared. you probably dont need the use the time warping functionality, just compute the similary using the common months across all states. Please check the doc to see how to disable time warping in proc similarity.

once similar state(s) are found, you first take the simple average of similar states by each year/month. Then you compare the difference between the state averages with the state with short history using the months when data is available in all states. For example, the state average/state with short histoty is 1.5. You then copy the state averages for the missing months and adjust the averages down by a factor of 1.5. you can make the adjustment factor by month as well.

**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.

Multiple Linear Regression in SAS

Learn how to run multiple linear regression models with and without interactions, presented by SAS user Alex Chaplin.

Find more tutorials on the SAS Users YouTube channel.