Statistical Procedures

Programming the statistical procedures from SAS
BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
Philip847
Calcite | Level 5

Hi All

The problem: I am using SAS QLIM to generate an Ordered Probit analysis using the folowing code:

 

proc qlim;

class <variable names> ;

Model DV = IVs / discrete ;

Ouptut out = <output dataset name> marginal ;

 

My DV is an ordinal variable with three levels, coded 0,1,2 where 0= Competely disagree; and 2= Completely agree. IVs are a mixture of binary, ordinal and interval variables.

 

This code generates marginal estimates for each of the IVs for each of the DV levels 1 and 2, but not for 0. My question is: Is it possible to generate Marginal Estimates for all three levels of the DV (not just two)? I have seen comments online that I might need a macro to do this, but I have never used SAS macro before.

 

Many thanks,

 

Philip

1 ACCEPTED SOLUTION

Accepted Solutions
SteveDenham
Jade | Level 19

Borrowing from @Rick_SAS :

Do you have other questions? If not, you can close this thread by choosing a response to mark as the "Accepted Solution."

 

SteveDenham

View solution in original post

3 REPLIES 3
SteveDenham
Jade | Level 19

From the QLIM documentation (the first example - Ordered Data Modeling), I found this:

 

By default, ordinal probit/logit models are estimated assuming that the first threshold or limit parameter (mu1) is 0. However, this parameter can also be estimated when the LIMIT1=VARYING option is specified.  

 

There is code immediately following that looks like

 

/*-- Ordered Probit --*/
proc qlim data=docvisit;
   model dvisits = sex age agesq income levyplus
                   freepoor freerepa illness actdays hscore
                   chcond1 chcond2 / discrete(d=normal) limit1=varying;
run;

My first thought about this would be that your IV's are not all interval variables, and so there are going to be levels of the categorical variables set to 0.  

You might consider using the OUTPUT statement to get marginal values or predicted values, and then post-processing those.

 

SteveDenham

 

Philip847
Calcite | Level 5

Hi Steve

 

That worked perfectly. Thank you very much for your help.

 

Best wishes

 

Philip

SteveDenham
Jade | Level 19

Borrowing from @Rick_SAS :

Do you have other questions? If not, you can close this thread by choosing a response to mark as the "Accepted Solution."

 

SteveDenham

sas-innovate-wordmark-2025-midnight.png

Register Today!

Join us for SAS Innovate 2025, our biggest and most exciting global event of the year, in Orlando, FL, from May 6-9. Sign up by March 14 for just $795.


Register now!

What is ANOVA?

ANOVA, or Analysis Of Variance, is used to compare the averages or means of two or more populations to better understand how they differ. Watch this tutorial for more.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 3 replies
  • 772 views
  • 4 likes
  • 2 in conversation