Hi,
I'm running proc gee for a multinominal outcome (0 1 2 3 4, with ref = 0). I would like to find the odds ratio for a continuous predictor using the Estimate statement (please see code below).
However, in my estimates table, I notice that I do get an estimate but the outcome column shows "0" instead of 1, 2,3, or 4.
Could someone verify if my code is written correctly?
Thanks in advance!
Proc GEE Data = Test;
Class =schoolid outcome year (ref = "0");
Model outcome (ref = "0") = year age;
Repeated subject = schoolid / type = ind;
Estimate "1 vs 0" Age 1 / exp cl;
Estimate "2 vs 0" Age 2 / exp cl;
Estimate "3 vs 0" Age 3 / exp cl;
Estimate "4 vs 0" Age 4 / exp cl;
LSMEANS Year /diff oddsratio cl ;
Run;
See this note that discusses and illustrates the use of the CATEGORY= option with multinomial models. The example shows the model fit by PROC LOGISTIC, but should apply to your GEE model.
Could you post the output you are unclear about?
Here's the output:
Also, I realized in the log, it says "Note: Results for ESTIMATE statements without a CATEGORY= option apply to the response level '0' ".
How does the category option work?
See this note that discusses and illustrates the use of the CATEGORY= option with multinomial models. The example shows the model fit by PROC LOGISTIC, but should apply to your GEE model.
Great! Thank you! Just to be clear, the only difference between Category = Separate and Category = Joint is how the output is presented. The separate statement presents each comparison in its own table vs the joint table puts it all together. Is that correct?
It may not hurt to show the LOG with the code actually submitted and any notes.
I would expect an ERROR message and no output generated because of the = in the CLASS statement.
Modifying one of the GEE example to show what happens when an equal sign is present on the CLASS statement:
540 proc gee data=Resp descend; 541 class= ID Treatment Center Sex Baseline; ----- 180 ERROR 180-322: Statement is not valid or it is used out of proper order. 542 model Outcome=Treatment Center Sex Age Baseline / 543 dist=bin link=logit; 544 repeated subject=ID(Center) / corr=exch corrw; 545 run; WARNING: No MODEL statement has been specified. No analysis will be done.
So make sure the code you share is actually what generates the output.
@varatt90 wrote:
Hi,
I'm running proc gee for a multinominal outcome (0 1 2 3 4, with ref = 0). I would like to find the odds ratio for a continuous predictor using the Estimate statement (please see code below).
However, in my estimates table, I notice that I do get an estimate but the outcome column shows "0" instead of 1, 2,3, or 4.
Could someone verify if my code is written correctly?
Thanks in advance!
Proc GEE Data = Test; Class =schoolid outcome year (ref = "0"); Model outcome (ref = "0") = year age; Repeated subject = schoolid / type = ind; Estimate "1 vs 0" Age 1 / exp cl; Estimate "2 vs 0" Age 2 / exp cl; Estimate "3 vs 0" Age 3 / exp cl; Estimate "4 vs 0" Age 4 / exp cl; LSMEANS Year /diff oddsratio cl ;
Run;
SAS Innovate 2025 is scheduled for May 6-9 in Orlando, FL. Sign up to be first to learn about the agenda and registration!
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.