# Formation of the test statistic in one-way ANOVA

From nist for the test statistic in one-way ANOVA:

The mean squares are formed by dividing the sum of squares by the associated degrees of freedom.

Let $N = \sum_i n_i$. Then, the degrees of freedom for treatment, $DFT = k - 1$, and the degrees of freedom for error, $DFE = N - k$.

The corresponding mean squares are:

$MST = SST / DFT$

$MSE = SSE / DFE$

I was wondering why the degrees of freedom for the two sums are given as $k-1$ and $N-k$, where $N$ is the sample size and $k$ is the number of groups? For the definitions of the two sums $SST$ (sum of squares of treatments) and $SSE$ (sum of squares of errors), see another page.

So dividing a sum of squares by its degree of freedom isn't "mean square", isn't it? Why does it say "the mean squares are formed by dividing the sum of squares by the associated degrees of freedom"?

Thanks and regards!

We compute the squares (that we will sum) by subtracting a mean from the observations, then squaring. If we knew the true population mean(s) and subtracted those true means from the observations then the resulting squares would be independent and it would be appropriate to divide by $k$ and $N$. But if we knew the true means then we would not need to compute mean squares anyways. Instead we are subtracting a mean that was computed from the same observations that we are subtracting it from, so the squares are not fully independent. The degrees of freedom represent the amount of independent information available in the squares being summed, that is why we divide by the d.f.