Cross Validated is a question and answer site for people interested in statistics, machine learning, data analysis, data mining, and data visualization. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I've made a logistic regression model that includes a polynomial term to degree 2. I'm aware that logistic regression models the response variable as a non-linear function of the predictors. Does it make sense to include a polynomial term in logistic regression?

share|improve this question
This is fine. If you'd like, you can see an example in my recent answer here: CDF and logistic regression. – gung Mar 31 '14 at 14:26

Logistic regression models the log odds of a "1" or "success" response as a linear function of the regression coefficients (i.e. the parameters), but there's no need to insist that the log odds be a linear function of predictors.

[This model is linear in parameters & the predictor: $$\operatorname{logit}\pi_i = \beta_0 + \beta_1 x_i$$ This one is linear in only the parameters: $$\operatorname{logit}\pi_i = \beta_0 + \beta_1 x_i + \beta_2 x_i^2$$ ]

Just as with ordinary least-squares regression, polynomial predictor terms can be used if required by theory or simply to allow for curvature in empirical models.

share|improve this answer
Correct me if I'm wrong, but the formula to convert predicted values from log odds to probabilities (values between 0-1) is non-linear. So doesn't logistic regression already allow for curvature? – luciano Mar 31 '14 at 14:21
+1, however, the phrasing is somewhat ambiguous: being 'linear' means linear in the parameters which is unaffected by the existence of polynomial terms. I know you understand this, but the latter half of your first sentence might confuse people who don't on that issue. Would you mind tweaking the phrasing a little? – gung Mar 31 '14 at 14:24
luciano: If you want to think of it in terms of the probability; then yes, its a curved relationship, but still restricted in form - rotational symmetry around the point of inflection at the inflection point at $\pi=\frac{1}{2}$ - you can only shift or stretch the logistic curve when you fit the two parameters. Polynomials allow more flexibility. See @gung's link for an example. – Scortchi Mar 31 '14 at 14:55

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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