Hello, I am looking to center a covariate, per the reference below. This covariate is Hospital Referral Region (HRR), which has 306 values and enters my model as 305 indicator variables. I also use this variable in interaction terms in the model.

Per Kraemer and Blaysey (and Cronbach's) recommendations, the indicator variables should be recoded from 1 and 0 to 1-1/m and -1/m, with one (arbitrary) HRR eliminated. I'd welcome any suggestions on how to easily code this in Stata.

Kraemer HC & Blasey CM. Centring in regression analyses: a strategy to prevent errors in statistical inference. International Journal of Methods in Psychiatric Research, 13: 3.