When we use dummy encoding in logistic regression, then we can interpret coefficients as log of ratio of odds (relative to some base value).

I am curious what is interpretation of coefficients when we use one hot encoding?

Update: by dummy encoding I mean "reference level coding" and by one hot encoding I mean "level means coding" as stated by gung in the following post proper teminology

  • 1
    $\begingroup$ By "one hot encoding" do you mean reference level coding or level means coding (see here for examples) or something else, in this case? $\endgroup$ Jun 14, 2017 at 18:21
  • $\begingroup$ @gung Thank you for your comment. It seems like reference level coding is superior as it it allows us to compare coefficients in terms of log odds. $\endgroup$ Jul 17, 2017 at 0:05

1 Answer 1


I think there are two issues here. The first is to be clear about how the levels of a categorical variable are being represented in a model. This is the issue of whether reference level coding or level means coding is being used. (See my answer here: How can logistic regression have a factorial predictor and no intercept?; n.b., those terms are indigenous to statistics, it is perfectly fine to call them dummy coding and one-hot encoding—so long as you are clear what is meant—if that is the terminology used in your field.)

The second issue is is to be clear on the nature of logistic in logistic regression. To wit: the logistic is a transformation (and moreover, the logit is the inverse transformation; see my answer here: What is the difference between logistic and logit regression?). In a logistic regression model, the logit is the link function.

The interpretation of the model's fitted coefficients depends on both how the variables are represented and the link function used. If you use the logit (as with logistic regression), the linear predictor is on the log odds scale. (For example, if you used the probit, that is not quite true, see: Difference between logit and probit models.) Thus, with logistic regression, your coefficients will be log odds or log odds ratios of something (with what depending on how your variables are coded). Namely, the coefficients associated with the intercept for reference level coding and with all levels of the categorical variable for level means coding will be log odds. On the other hand, with reference level coding the coefficients for all indicated levels (i.e., other than the reference level) will be log odds ratios. More specifically, they will be the log of the odds ratio associated with moving from the reference level to the indicated level.


Your Answer

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

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