Hi all,
One question,
when i run a logistic regression with a binned variable (age in 3 categories) and i use the 1st group as reference group, which beta estimate does it get?
because i get an estimate for the other two groups but not for that one or am I mistaken?
The reason i am asking cause i would like to have the according estimates so as to calculate the probability myself but i will be missing out on cases where the id falls into the 1st bin.
Regards,
You don't get an estimate for that group. Make sure to specify PARAM=REF in your model.
IE. If you have three variables, that gets recoded to 2 binary variables. When both are 0 then the third/reference level is true.
Beta estimate for reference group will not be used for probability calculations. Because there will be no dummy variable for this one in the model.
ok so how can an id which falls into that bin get a probability then?
If you have no other variables it's the intercept, if you have other variables its the equation without that variable.
Lets assume you have a variable AGE with 3 categories: 1, 2, 3. Reference level is set to 1.
X1=1 if age=2
X1=0 if age=1,3
X2=1 if age=3
X2=0 if age=1,2
Model = Intercept + B1*X1 + B2*X2
If Age=1 then
Model = Intercept
If Age=2 then
Model = Intercept + B1*X1
If Age=3 then
Model = Intercept + B2*X2
You calculate it from the intercept(parameter).
meaning an id with ref 1 for age and 0 for gender what predicted probability will it get?
aha ok, sure that makes sense, thank you very much for the reply and example it was really helpful, by the way you wouldnt happen to have any good example on creating the KS chart in excel?
What is a KS chart?
Kolmogorov Smirnof chart
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!
Use this tutorial as a handy guide to weigh the pros and cons of these commonly used machine learning algorithms.
Find more tutorials on the SAS Users YouTube channel.