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

I am doing reference cell coding with a binary categorical predictor.

According to max likelihood table,

Intercept = 0.2335, and that is the predicted logit probability of the reference level.

However, the effect plot shows a dot at >0.50 for the predicted probability of that level.

Why is that? Please let me know possible explanations.

proc logistic data=have plots(only)=(effect oddsratio);
    class x(ref='<=60 min')/ param=ref;
    model y(event='1')= x / clodds=pl;
run;

 

1 ACCEPTED SOLUTION

Accepted Solutions
Rick_SAS
SAS Super FREQ

You can get the exact predicted values by using

ods output effectplot=EFPLOT;

proc logistic....

run;

proc print data=EFPLOT; run;

 

The estimate for the Intercept (reference level) is 0.2335.

Then the predicted value for the reference category is 

p = logistic( 0.2335 );

which is 0.5581. This looks like the height of the dot for the reference category, so it looks like all is well. If the height is different from 0.5581, let me know.

 

View solution in original post

6 REPLIES 6
Rick_SAS
SAS Super FREQ

Can you upload the image so we can see it?

pink_poodle
Barite | Level 11

maximum likelihood tablemaximum likelihood tableeffect ploteffect plot

Rick_SAS
SAS Super FREQ

You can get the exact predicted values by using

ods output effectplot=EFPLOT;

proc logistic....

run;

proc print data=EFPLOT; run;

 

The estimate for the Intercept (reference level) is 0.2335.

Then the predicted value for the reference category is 

p = logistic( 0.2335 );

which is 0.5581. This looks like the height of the dot for the reference category, so it looks like all is well. If the height is different from 0.5581, let me know.

 

pink_poodle
Barite | Level 11

The ods output value is 0.558105622519328. Thank you!

pink_poodle
Barite | Level 11

Double-checked the logistic function:

 

logit(p) = ln(odds) 

let logit(p) = a

odds = p / ( 1 - p )

p / (1 - p) = e^a

p  = e^a - p*e^a

p*(1 + e^a) = e^a

p = e^a / (1 + e^a) = logistic(a)

 

 

 

Rick_SAS
SAS Super FREQ

Yes. Equivalently, p = 1 / (1 + exp(-a)), which is shorter to write.

SAS Innovate 2025: Register Now

Registration is now open for SAS Innovate 2025 , our biggest and most exciting global event of the year! Join us in Orlando, FL, May 6-9.
Sign up by Dec. 31 to get the 2024 rate of just $495.
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
  • 6 replies
  • 1265 views
  • 3 likes
  • 2 in conversation