12-13-2012 10:10 AM
I have data with missing values at the end of the time series. I have different products and the amount of missing monthly values varies by item and by year. How do I forecast/extrapolate these missing values only? (without going beyond the year in which the item is purchased)
Item year month value
a 2000 1 12
a 2000 2 243
a 2000 3 234
a 2000 4 123
a 2000 5 23
a 2000 6 .
a 2000 7 .
a 2000 8 .
a 2000 9 .
a 2000 10 .
a 2000 11 .
a 2000 12 .
When i use proc forecase, it is not forecasting the missing values. But based on the example above, it would only extrapolate 12 values for 2001.
Here is the base code that i am using.
proc forecast data=old out=new
id month; *month is date variable with format monyy;
Perhaps another procedure would work? Any suggestions?
12-21-2012 01:54 PM
As an alternative you might consider PROC ESM instead.
Here is an example.
set sashelp.air(in=l) sashelp.air;
if l then do;
if date ge "01JAN1960"d then air=.;
if date ge "01JUN1960"d then air=.;
proc sort data=example;by group date;run;
proc esm data=example out=_null_ outfor=want lead=0;
id date interval=month ;
forecast air / method=winters;
Need further help from the community? Please ask a new question.