1
$\begingroup$

I have a predictor variable of type factor which contains the date of birth. From your experience (when dealing with logistic regression), what is the best way of treating date of birth (or similar types)? As a continuos variable or maybe or maybe as a categorical variable which stores different age segments?

$\endgroup$
3
  • 1
    $\begingroup$ Date of birth is intrinsically important for calculating what is allowed or expected in society (can you drive a car legally, do you qualify for a pension?), so for such purposes it should remain human-readable. Often date of birth is important in giving age, for which the needed precision may mean hours or days (for new-borns) or the allowed precision may just be years (for older people). Either way, converting date of birth to number of days or years since time origin seems most usual for statistical analysis. $\endgroup$
    – Nick Cox
    Commented May 7, 2013 at 18:39
  • 1
    $\begingroup$ @NickCox It is slightly paradoxical but your examples would seem to argue against using number of days since time origin, e.g. you are either of driving age or you are not, this is intrinsically binary. $\endgroup$
    – Gala
    Commented May 7, 2013 at 20:00
  • $\begingroup$ No paradox. I am distinguishing (a) social and (b) statistical purposes for which (a) human-readable dates such as "7 May 2013" are needed and (b) fully quantitative dates are needed, e.g. if 1 Jan 1960 = 0, then 7 May 2013 = 19485. Sorry that was not clear to you. $\endgroup$
    – Nick Cox
    Commented May 7, 2013 at 21:16

1 Answer 1

1
$\begingroup$

Depends on what you're trying to model. In general you're losing information by binning a continuous predictor, but there are situations where it makes sense, e.g. as a proxy for 'minor' vs 'of legal age' or "of working age" vs "retired". It can sometimes also be a useful way to informally check the predictor's relation to the response in logistic regression. And if you have plenty of degrees of freedom to spare, & are lazy, it saves you checking the nature of the relation to the response.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.