can i use logistic regression in discrete feature types can i use logistic regression in discrete feature types problem. Since recently i knew that the expression for logistic regression is derived from guassian naive bayes and we can use guassian naive bayes if only our features are continous.  
 A: By discrete, do you mean:


*

*Integers (11, 4, 9, ...)

*Ordinal (low=1, medium=2, high=3, superhigh=4, ...)

*Categorical (red, blue, orange, ...)


?
You can use all such variables, but you should keep in mind the following caveats / best practices:


*

*Integers: fine to use as they are! but consider scaling by mean/stddev to z-scores

*Ordinal: also fine to use, but consider that the difference between 1 -> 2 might be different than 2 -> 3. The relationship may not be linear. You may wish to treat them as categorical or as integers transformed quadratically, logarithmically, etc. You'll have to experiment and see what works best. 

*Categorical: here you will need to one-hot or "dummy" encode these. So your color variable with 4 colors becomes a vector of [0 0 0 1] where each new "dummy" variable stands for a color (either there, or not). This has the nice property of allowing you to specify multiple colors if you so desire. (Note also that if you're encoding N=4 colors, you can get away with using only 3 dummy variables, and the absence of any 1's is the last color, so long as you don't need multiple colors represented. But I digress.)


Any of the encodings above will let you represent it in a way that logistic regression can happily handle. 
Remember to scale your inputs if possible though! This often has a large impact on the speed of convergence of the logistic regression solver. And of course, scale your test set by the train set's means and variances, not the test set's (that's cheating!). 
