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

I'm trying to run the proc genmod command, but when I look at level 3, it has 0s across the board but levels 1 and 2 have values. How do I get my level 3 data to show up? I dont know how to code for a dummy variable to get the 3rd level. Any help is appreciated! 

 

Data UGAStudent_DATA;
Set date_difference; 

if cd4 <= 200 then cd4_levels='1';
if cd4 >=201 <=500 then cd4_levels='2';
if cd4 > 500 then cd4_levels='3'; 
run;

proc genmod data= ugastudent_data;
class cd4_levels /param=glm ;
model  Factor1 =  cd4_levels n_Duration_on_ART_months ;  
run;
1 ACCEPTED SOLUTION

Accepted Solutions
Reeza
Super User

Same answers here, for R if that helps at all with the explanation.

This is one of those cases where you need to understand the underlying statistical concepts, specifically: Degrees of Freedom, dummy coding and an over parameterized models. 

Those are some key words you can use to search to explain these results.

 

https://community.alteryx.com/t5/Advanced-Analytics/In-the-Logistic-Regression-Report-Factor-Missing...

View solution in original post

4 REPLIES 4
Reeza
Super User

Same answer as before. I'll move this to the Stats forum in case others want to chime in. 

 

 

Reeza
Super User

Same answers here, for R if that helps at all with the explanation.

This is one of those cases where you need to understand the underlying statistical concepts, specifically: Degrees of Freedom, dummy coding and an over parameterized models. 

Those are some key words you can use to search to explain these results.

 

https://community.alteryx.com/t5/Advanced-Analytics/In-the-Logistic-Regression-Report-Factor-Missing...

art297
Opal | Level 21

As others have sort of mentioned, proc genmod automatically creates dummy variables. And, with any combination of n dummy variables, all of the variance that can be explained is accounted for by n-1 of the dummy variables.

 

Art, CEO, AnalystFinder.com

 

hackathon24-white-horiz.png

2025 SAS Hackathon: There is still time!

Good news: We've extended SAS Hackathon registration until Sept. 12, so you still have time to be part of our biggest event yet – our five-year anniversary!

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
  • 4 replies
  • 2541 views
  • 0 likes
  • 3 in conversation