One step ahead forecast from an estimated model - error term

조회 수: 9 (최근 30일)
na ja
na ja 2016년 9월 17일
댓글: Lorenzo 2023년 1월 21일
I have estimated the model for my series and it is arima(1,1,1). Instead of available k-step ahead option, I need to do one-step ahead forecast. The model is:
ARIMA(1,1,1) Model:
--------------------
Conditional Probability Distribution: Gaussian
Standard t
Parameter Value Error Statistic
----------- ----------- ------------ -----------
Constant 8.96034e-05 0.00121444 0.0737815
AR{1} 0.531086 0.0802215 6.62025
MA{1} -0.917878 0.0394706 -23.2548
Variance 0.0378884 0.00419511 9.03158
so, the equation will be
y(k) = .000089 + (0.531086*y(k-1)) + e(k) + (-0.917878*e(k-1))
What will be the value of 'e' term? what should be 'e(k)'? Correct me if I have interpreted anything wrongly.
  댓글 수: 3
Brendan Hamm
Brendan Hamm 2016년 9월 20일
Yes the model w ould be:
y(k) = .000089 + y(k-1) + [0.531086*(y(k-1) - y(k-2))] + e(k) + (-0.917878*e(k-1))
e(k) in this example is simply a Normal random variable with mean zero and variance 0.038 such e(k) is independent of e(k-t)) for all t.
Look at the forecast method, you should provide the pre-sample response 'Y0' and innovations 'E0'.
doc arima\forecast
Forecast provides MLE (i.e. all e sampled will be zero), but you can also use the simulate method to sample from that distribution:
doc arima\simulate
na ja
na ja 2016년 9월 22일
Thanks Brendan! Will do the same. I have one more doubt regarding statistical concept of ARIMA. As I have discussed above, this model is ARIMA(1,1,1). For one step ahead forecast I am using the equation
[y(k) - y(k-1)] = .000089 + [0.531086*(y(k-1) - y(k-2))] + e(k) + (-0.917878*e(k-1))
What will be the value of e(k-1) term to get 1st forecast (i.e. for k =1)? Is it the last value of residual matrix of training data or something else? I am bothered because according to the equation, i am predicting differences, not the actual values. The residual table gives the residuals for (actual values- predicted values).

댓글을 달려면 로그인하십시오.

채택된 답변

Brendan Hamm
Brendan Hamm 2016년 9월 22일
편집: Brendan Hamm 2016년 9월 24일
1. The arima\estimate method will return to you the data on the original scale. That is if you do:
Mdl = arima(1,1,1);
Mdl = estimate(Mdl,data);
res = infer(Mdl,data); % Retrieve inferred residuals (innovations)
foreValues = forecast(Mdl,1,'Y0',data','E0',res) % forecast
Your forecasted data will be on the same scale as data and not the differenced data. The difference operator is just applied and you have the model you wrote above, but are simply returned y(k),y(k+1),...
2. The residual e(k-1) is he last value in the variable res above. That is, if you pass 'E0' to the forecast method it will use the residuals which were infered from the model and data.
  댓글 수: 5
na ja
na ja 2016년 9월 26일
Thanks Brendan! That made it all clear. :)
Lorenzo
Lorenzo 2023년 1월 21일
Thank you for this answer! Can you then plot the forecasted values combined with the observed values so that we get a graph were we see the continuity between observed and forecasted values?

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Conditional Mean Models에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by