In Logistic Regression (as in regression in general), when it comes to check model's diagnostics, one has to check for observations with higher-than-average leverage.

From what I read in several sources, the average leverage is equal to (k+1)/N, where k is the number of predictors, and N the sample size. In literature, they propose 2 or 3 time the average leverage as threshold for "unacceptable" leverage. 

What I am wondering is if, when counting the number of predictors (i.e., devising k), do we have to also count the number of levels of categorical predictors?

In other words, if we have 1 continuous predictor and 1 categorical predictor with 3 levels, k would be:

2 (i.e., 1 continous predictor + 1 categorical predictor)

or

3 (i.e., 1 continuous predictor + 2 [i.e. the 3 levels of the categ predictor minus one due to dummy coding]) ?

I hope the quastion makes sense to you. Thank you in advance for any clarification.

More Gianmarco Alberti's questions See All
Similar questions and discussions