Sufficient dimension reduction in regressions with categorical predictors