In this question, it's explained how the intercept is fit under normal linear regression. It is given that it is calculated using

$$\beta_0 = \bar{y} - \sum_{j=1}^p \hat{\beta}_j \bar{x}_j$$

How is this done in the logistic case, because surely $\bar{y}$ is nothing sensible that should be used?

  • $\begingroup$ there's no formula that gives the intercept term for a logistic regression in the general case. Rather, the intercept, along with the other parameters, is estimated via an iterative method. The same is true for regularized logistic regression like glmnet. $\endgroup$ Apr 25, 2023 at 21:36


Your Answer

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

Browse other questions tagged or ask your own question.