SAS logistic regression

#1
Hello everyone,
I am using SAS studio to analyze data to predict risk factors for postpartum depression.
I tried running logestic regression for each potential risk factor but I encountered some issues that I need help with solving:

1) For one of the risk factors (sex discomfort) I was able to get the odds ratio for depression among those who do not have sex discomfort (0). I want to look at those depressed and have ex discomfort (1). How do I change that??
Here is my code:
proc logistic DATA=resJordan desc ;
class "Ppsexdiscomfort"n ;
model depres= "Ppsexdiscomfort"n;
run;

2) Some risk factors have very few positives. For instances only 10 out of 68 depressed mothers have sex discmfort. Is this a problem? and how large should the observations be in order for the logestic regression to be intrpretable in this case?

Thank you
 

hlsmith

Not a robit
#2
1) I don't understand your first question. Are you trying to just run the model on a subset of the sample?

2) If you have a sparse number of people in a group, this will result in larger SEs and wider confidence intervals. There is nothing you can do about it, beyond collecting more data or not oversaturating your model (too many predictors). If the sparseness is too extreme your model may not converge. It is typically recommended to use exact logistic regression or employ the Firth correction in these scenarios.
 

noetsi

Fortran must die
#3
It may attenuate the slope (at least if its a dummy predictor although I think 90 percent at one level is where it gets dangerous). According to various authors there are minimum requirements for the least common level of the dv although various authors disagree on them and they are rules of thumb not rules.
 

hlsmith

Not a robit
#4
Regardless, it comes down to common sense as well. If you have a rare outcome and an imbalanced categorical predictor - how well do those few individuals nested in those groups generalize to the super population. Do they represent everyone?