I understand that the fitted values for Logistic Regression can be expressed as:

$$P(Y_i=1) = \left(1+\exp(-\hat{\theta}^TX_i)\right)^{-1}$$

where $X_i$ is the feature vector, which will work well when the features take only numeric values.

However, when the features are non-numerical, can we use the same approach as given here for a Linear Regression model? Or is there a better way which we can use for Logistic Regression?


Coding of regressors are done exactly the same way in logistic regression as in linear regression. And, by the way, the same way in Poisson regression---all of the GLM's (generalized linear models). In fact, for a lot of other kind of models too. There may be some other considerations in addition, but the same principles apply.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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