Hi,
I am new to logistic reg so I think I am missing some basics on how to write equation from Maximum Likelihood Estimates.
I am in the final steps of scoring a dataset after building a Logistic Regression model. I have used Reference Cell coding for categorical variable. The confusion I have is:
If I use the Score statement in Proc Logistic, I get the output table with scored probabilities column called P_1. However, If I try to write equation from Maximum Likelihood Estimates, I get different probability values.
Why is that so? Is it because, in the equation, I am not mentioning the reference level for any categorical variable. Can someone please help me write equation for these results (just an example):
Maximum liklihood Coefficients:
Intercept: -0.2367
Var 1: Age_LE_18: This is reference level
Age_18_to_40: 0.3245
Age_Above_40: 0.4125
Var2 Good_credit_History: Reference Level
Bad_Credit_History: - 0.8795
The equation I am writing is: -0.2367 + 0.3245*(Var1='Age_LE_18') + 0.4125*(Var1='Age_Above_40') - 0.8795* (VAR2='Bad_Credit_History')
If you see, I am not mentioning Reference levels in my equation. If this is right, then why the probabilities do not match with Score Statement?
Thanks
Sachin
Usually this is because you're doing something wrong. Post your full SAS code, output and where you think it's wrong. Proc Logistic score output will match the hand calculated output. If you even search on here, you'll find examples where I've coded this out.
Usually this is because you're doing something wrong. Post your full SAS code, output and where you think it's wrong. Proc Logistic score output will match the hand calculated output. If you even search on here, you'll find examples where I've coded this out.
You right Reeza. I hadwrong value for one of the coefficients.
Thanks for the reply.
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!
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.