BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
Junyong
Pyrite | Level 9

The following code (1) downloads McDonald's stock prices from July 5, 1966 to November 1, 2021, (2) computes its percent returns, and (3) estimates the GARCH(1,1) model.

filename mcd url 'https://query1.finance.yahoo.com/v7/finance/download/
mcd?period1=-999999999&period2=9999999999';

proc import file=mcd dbms=csv replace out=mcd;
run;

proc expand out=mcd;
	id date;
	convert adj_close=return/tout=(pctdif);
run;

proc autoreg;
	model return=/garch=(q=1,p=1);
	output ht=variance out=mcd;
run;

Because ARCH1+GARCH1=0.0485+0.9539=1.0024>1, the unconditional variance is undefined. However, the output data set assigns 3.8592488163 as the variance of the first observation—how does AUTOREG compute this value of 3.8592488163 here? It seems this is not documented in The AUTOREG Procedure.

1 ACCEPTED SOLUTION

Accepted Solutions
Ksharp
Super User
It would be better if you post it at Forecasting forum,since it is about SAS/ETS

View solution in original post

1 REPLY 1
Ksharp
Super User
It would be better if you post it at Forecasting forum,since it is about SAS/ETS

SAS Innovate 2025: Call for Content

Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!

Submit your idea!

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
  • 1 reply
  • 503 views
  • 0 likes
  • 2 in conversation