How would you deal with a bimodally distributed predictor variable in bivariate logistic regression?

I am relating age to a binary outcome in a logistic model (or, more to the point I would like to). However, the distribution of the ages looks like this:

nn <- 1000
age <- c(rpois(nn / 3, lambda = 0.5),
rnorm(nn / 3, mean = 10, sd = 2),
runif(nn / 3, min = 0, max = 15))
age <- age[which(age > 0)]


How would you approach this problem?

Thanks!

-

Logistic (or other) regression does not make any assumptions about the distribution of the predictors, they are only assumed to be known exactly. So there is nothing stopping you from going ahead and using age in your regression model.

The issue you have to actually worry about is whether the effect of age is linear on the logit scale, but that has nothing to do with its distribution.

-
 Thanks! What is a good approach if it's not linear in the logit scale? – Andrew Dec 10 '10 at 23:52 You can try transformations (e.g. using user2040's suggestions), or splines. – Aniko Dec 11 '10 at 20:02

@andrew: I personally like a simple approach which is to create a logit plot where I would do something along the lines of binning age into 10 groups (deciles) and plotting the logit against these bins. This gives a sense for the linearity of the variable in the logit and may suggest a transformation.

-

If binning the age variable is an option, you might want to use a classification tree to get an idea of where to place the cutoffs.

-