Turn on suggestions

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

- Home
- /
- Analytics
- /
- Stat Procs
- /
- Logistic effect plot not corresponding to max likelihood table

Options

- RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page

🔒 This topic is **solved** and **locked**.
Need further help from the community? Please
sign in and ask a **new** question.

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

Posted 10-22-2019 12:40 PM
(1089 views)

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

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

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.

6 REPLIES 6

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

Can you upload the image so we can see it?

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

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.

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

The ods output value is 0.558105622519328. Thank you!

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

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)

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

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

Are you ready for the spotlight? We're accepting content ideas for **SAS Innovate 2025** to be held May 6-9 in Orlando, FL. The call is **open **until September 25. Read more here about **why** you should contribute and **what is in it** for you!

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.