Change Base Level Categorical Vector in GLM


Is there a way to change the base level of a categorical vector in GLM? It looks like the first level in the vector is chosen as the base level. I have tried to change the order of levels using levels! but it does not seem to make a difference


Check out the use of Contrasts in the StatModels package, which is what generates the model matrix in a GLM model.