Programming the statistical procedures from SAS

Macro Error Message

Reply
Occasional Contributor
Posts: 5

Macro Error Message

Hi All,

 

I am running the following SAS Macro %GLIMMIX and get the error mesage in the log file. Any Help to address it is apprecieated:

 

SAS CODE:

 

%INCLUDE "C:\Users\Mohsen\Desktop\PracticumCourse\5-Good\HPGLIMMIX\HPGLIMMIX.sas" ;


title "Using HPGLIMMIX macro";
%hpglimmix(data=library.projectfulldata,
stmts=%str(
class id age;
model stopcorrect= age/s;
random int/subject=id;
),
error=binomial, maxit=50,
link=logit,
);

 

SAS LOG FILE:

 

options mlogic symbolgen mprint;
 %INCLUDE "C:\Users\Mohsen\Desktop\PracticumCourse\5-Good\HPGLIMMIX\HPGLIMMIX.sas" ;

 title "Using HPGLIMMIX macro";
 %hpglimmix(data=library.projectfulldata,
MLOGIC(HPGLIMMIX): Beginning execution.
stmts=%str(
class id age;
model stopcorrect= age/s;
 random int/subject=id;
13867 ),
13868 error=binomial, maxit=50,
13869 link=logit,
);
ERROR: All positional parameters must precede keyword parameters.

Super User
Posts: 5,246

Re: Macro Error Message

The error is caused by the final comma:

 

link=logit,)

 

This makes it look like you meant to add a value for another macro parameter (giving it a null value).  Just get rid of the comma and you should be fine.

Occasional Contributor
Posts: 5

Re: Macro Error Message

Thank you very much !   It Worked .

Ask a Question
Discussion stats
  • 2 replies
  • 246 views
  • 0 likes
  • 2 in conversation