I have a dataset which contains only categorical data i.e.A,B,C,D
(like factors) for each predictor. There are 10 predictors and the dependent variable is binary, 0,1
.
UPDATE: MY predictors are answers for multiple choice questions for a questionnaire. So each predictor only takes on categorical values, i.e. X_1
can be A,B,C
or D
, X_2
can be A,B,C,D,E,F,G
or H
.
Is it feasible to fit a logistic regression over this dataset? Ideally, if I can fit a logistic regression the data, I will then use it for prediction over a set of test data, which again contains only categorical data.
What are the pitfalls that I should look out for?
1
. Ifp <0.5
, then response variable should be be0
. And regarding binning levels of each predictor, since all my predictors have values likeA,B,C
and number of levels for each predictor is different, can I just useas.factor
for all the predictor variables ? $\endgroup$