Displaying 1 result from an estimated 1 matches for "vararat".
Did you mean:
varacat
2011 Aug 03
1
Coefficient names when using lm() with contrasts
Dear R Users,
Am using lm() with contrasts as below. If I skip the contrasts()
statement, I get the coefficient names to be
> names(results$coef)
[1] "(Intercept)" "VarAcat" "VarArat" "VarB"
which are much more meaningful than ones based on integers.
Can anyone tell me how to get R to keep the coefficient names based on the
factor levels whilst using contrasts rather than labelling them with
integers?
Many thanks in advance,
Pete
Cardiff, UK
> dt=...