I am currently analysis a data set containing 654281 observations and 27 variables. I aim to perform binary logistic regression and many of my variables are categorical.
I know one hot encoding is supposed to help with the performance of the classification model but I do not know how many variables to do it on.
Of my 27 variables, 23 are categorical, so in theory I should encode all of them. However, some of them have a ridiculous amount of levels. The levels range from 2 to 80,677, e.g. one being 35, one 738, one 13000. I am not sure if I need to encode them all, as it makes my data set incredibly large with a ridiculous amount of variables. Should I only encode the ones with a small number of levels, if so, what is the cut off point?