Programming the statistical procedures from SAS

How to write deviation contrast code for dummy variable categories which are not mutually exclusive?

Reply
Frequent Contributor
Posts: 81

How to write deviation contrast code for dummy variable categories which are not mutually exclusive?

I'm working on a healthcare logistic regression predicting probability of hospitalization based on a collection of demographic predictors and for a collection of 58 yes/no dummy variables measuring medical & behavioral diagnosis categories.

My question: How do you properly code categorical dummy variables using deviation contrast coding (as described on the ATS UCLA website

http://www.ats.ucla.edu/stat/sas/webbooks/reg/chapter5/sasreg5.htm#DEVIATION) when

1) All patients have at least one medical or behavioral diagnosis, and

2) The values of the categorical variable in question are not mutually exclusive (patients may have multiple diagnoses)?

The deviation contrast coding rules specify that the sum of possible contrast variable values sum to zero, but I'm not sure how to apply these rules to my situation where multiple diagnoses are possible.

Ask a Question
Discussion stats
  • 0 replies
  • 196 views
  • 0 likes
  • 1 in conversation