Dear experts,
I tried to run:
PROC HPMIXED DATA=work.fiscal COVTEST NOCLPRINT NAMELEN=100 IC METHOD=REML lognote lognote;
CLASS i f c year;
MODEL roa = year/ SOLUTION CL CHISQ DDFM=RESIDUAL NOTEST;
RANDOM year INTERCEPT / TYPE=AR(1) subject=i;
RANDOM INTERCEPT / TYPE=VC subject=f(i);
RANDOM INTERCEPT / TYPE=VC subject=c(f i);
REPEATED year/ TYPE=AR(1) SUBJECT=f(i);
RUN;
But I got below error message:
72 PROC HPMIXED DATA=work.fiscal COVTEST NOCLPRINT NAMELEN=100 IC METHOD=REML lognote lognote;
NOTE: Writing HTML Body file: sashtml.htm
72 PROC HPMIXED DATA=work.fiscal COVTEST NOCLPRINT NAMELEN=100 IC METHOD=REML lognote lognote;
-------
22
ERROR 22-322: Syntax error, expecting one of the following: ;, (, BLUP, DATA, IC, INFOCRIT, ITDETAILS, LOGNOTE, MAXCLPRINT,
METHOD, MMEQ, NAMELEN, NLPRINT, NOCLPRINT, NOFIT, NOINFO, NOITPRINT, NOPRINT, NOPROFILE, ORDER, RANKS, SIMPLE,
SINGCHOL, SINGRES, SINGULAR, UPDATE.
72 PROC HPMIXED DATA=work.fiscal COVTEST NOCLPRINT NAMELEN=100 IC METHOD=REML lognote lognote;
-------
202
ERROR 202-322: The option or parameter is not recognized and will be ignored.
72 PROC HPMIXED DATA=work.fiscal COVTEST NOCLPRINT NAMELEN=100 IC METHOD=REML lognote lognote;
------
73
ERROR 73-322: Expecting an =.
72 PROC HPMIXED DATA=work.fiscal COVTEST NOCLPRINT NAMELEN=100 IC METHOD=REML lognote lognote;
------
76
ERROR 76-322: Syntax error, statement will be ignored.
NOTE: PROCEDURE HPMIXED used (Total process time):
real time 0.62 seconds
cpu time 0.51 seconds
NOTE: The SAS System stopped processing this step because of errors.
73 CLASS i f c year;
74 MODEL roa = year/ SOLUTION CL CHISQ DDFM=RESIDUAL NOTEST;
75 RANDOM year INTERCEPT / TYPE=AR(1) subject=i;
76 RANDOM INTERCEPT / TYPE=VC subject=f(i);
77 RANDOM INTERCEPT / TYPE=VC subject=c(f i);
78 REPEATED year/ TYPE=AR(1) SUBJECT=f(i);
79 RUN;
Could someone please help me with this issue? Thank you very much!
I'm not an expert on HPMIXED, but will give it a shot...
1) Start with a fresh SAS session - something upstream of PROC HPMIXED (missing semicolon, missing %mend, etc) could be a problem.
2) If your upstream code is creating work.fiscal, temporarily write it to a permanent library (for example sasuser), then again start with a fresh SAS session, and just submit your PROC HPMIXED step.
3) Validate your HPMIXED syntax against https://support.sas.com/documentation/cdl/en/statug/63962/HTML/default/viewer.htm#statug_hpmixed_sec.... For example, I don't see a COVTEST option, but I didn't search the doc very hard, and I'm sure you know the HPMIXED syntax better than me.
First, always use the {i} button for posting logs, as it makes the log clearer:
72 PROC HPMIXED DATA=work.fiscal COVTEST NOCLPRINT NAMELEN=100 IC METHOD=REML lognote lognote; ------- 22 ERROR 22-322: Syntax error, expecting one of the following: ;, (, BLUP, DATA, IC, INFOCRIT, ITDETAILS, LOGNOTE, MAXCLPRINT, METHOD, MMEQ, NAMELEN, NLPRINT, NOCLPRINT, NOFIT, NOINFO, NOITPRINT, NOPRINT, NOPROFILE, ORDER, RANKS, SIMPLE, SINGCHOL, SINGRES, SINGULAR, UPDATE. 72 PROC HPMIXED DATA=work.fiscal COVTEST NOCLPRINT NAMELEN=100 IC METHOD=REML lognote lognote; ------- 202 ERROR 202-322: The option or parameter is not recognized and will be ignored. 72 PROC HPMIXED DATA=work.fiscal COVTEST NOCLPRINT NAMELEN=100 IC METHOD=REML lognote lognote; ------ 73 ERROR 73-322: Expecting an =. 72 PROC HPMIXED DATA=work.fiscal COVTEST NOCLPRINT NAMELEN=100 IC METHOD=REML lognote lognote; ------ 76 ERROR 76-322: Syntax error, statement will be ignored.
Maxim 1: Read the Documentation. The documentation for the HPMIXED statement does not mention a COVTEST or METHOD option at all, and the IC option expects an equal sign and the type of information criteria.
@Kurt_Bremser @ScottBass Thank you all very much! I'll carefully read what you shared and do some research on how do deal with this.
It's finally time to hack! Remember to visit the SAS Hacker's Hub regularly for news and updates.
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.
Ready to level-up your skills? Choose your own adventure.