# About Effect Coding: It is possible to include μ “mu” and all the τ “tau” in a β matrix? [closed]

Is it mandatory to have a comparison group (one "tau" is coded as -1 and it does not have its own column)? If it is mandatory, can you explain why?

I am trying to represent the model Y=Xb+e in matrices. I have an X matrix that is a 24x3 matrix and includes a column called "mu" that only has 1, a column called tau1 and a column called tau2, tau 3 do not have a column, instead, tau3 is represented by -1 at the end of columns tau1 and tau2. I also have a b matrix that is a 3x1 matrix, that includes "mu", tau1 and tau 2. My question is: can I include in my X matrix a column for tau3 and replace the -1 for zeros(24x4)?, also, can I include the tau3 in my beta matrix (4x1)?

• I am trying to represent the model Y=Xb+e in matrices. I have an X matrix that is a 24x3 matrix and includes a column called "mu" that only has 1, a column called tau1 and a column called tau2, tau 3 do not have a column, instead, tau3 is represented by -1 at the end of columns tau1 and tau2. I also have a b matrix that is a 3x1 matrix, that includes "mu", tau1 and tau 2. My question is: can I include in my X matrix a column for tau3 and replace the -1 for zeros(24x4)?, also, can I include the tau3 in my beta matrix (4x1)? – Casildin Sep 11 '17 at 19:21

## 1 Answer

In effect coding, there is a reference category. That's part of the definition of effect coding so, the simple answer to your question is that it is mandatory. The reason is that you have to compare to some level.

However, there are other parameterizations of categorical variables. You can compare to the overall mean (deviation coding) or to the mean of subsequent levels (Helmert coding) and there are other choices too. For more see this article.