 7. Product and Process Comparisons
7.4. Comparisons based on data from more than two processes
7.4.3. Are the means equal?

## One-way ANOVA calculations

Formulas for one-way ANOVA hand calculations Although computer programs that do ANOVA calculations now are common, for reference purposes this page describes how to calculate the various entries in an ANOVA table. Remember, the goal is to produce two variances (of treatments and error) and their ratio. The various computational formulas will be shown and applied to the data from the previous example.
Step 1: compute $$CM$$ STEP 1 Compute $$CM$$, the correction for the mean. $$CM = \frac{ \left( \sum_{i=1}^3 \sum_{j=1}^5 y_{ij} \right)^2}{N_{total}} = \frac{(\mbox{Total of all observations})^2}{N_{total}} = \frac{(108.1)^2}{15} = 779.041$$
Step 2: compute $$SS(Total)$$ STEP 2 Compute the total $$SS$$.

The total $$SS$$ = $$SS(Total)$$ = sum of squares of all observations $$- CM$$. $$\begin{eqnarray} SS(Total) & = & \sum_{i=1}^3 \sum_{j=1}^5 y_{ij}^2 - CM \\ & & \\ & = & (6.9)^2 + (5.4)^2 + \ldots + (6.9)^2 + (9.3)^2 - CM \\ & & \\ & = & 829.390 - 779.041 = 45.439 \end{eqnarray}$$ The value of 829.390 is called the "raw" or "uncorrected " sum of squares.

Step 3: compute $$SST$$ STEP 3 Compute $$SST$$, the treatment sum of squares.

First we compute the total (sum) for each treatment. $$\begin{eqnarray} T_1 & = & 6.9 + 5.4 + \ldots + 4.0 = 26.7 \\ & & \\ T_2 & = & 8.3 + 6.8 + \ldots + 6.5 = 38.6 \\ & & \\ T_3 & = & 8.0 + 10.5 + \ldots + 9.3 = 42.8 \end{eqnarray}$$ Then, $$SST = \sum_{i=1}^3 \frac{T_i^2}{n_i} - CM = \frac{(26.7)^2}{5} + \frac{(38.6)^2}{5} + \frac{(42.8)^2}{5} - 779.041 = 27.897 \, .$$

Step 4: compute $$SSE$$ STEP 4 Compute $$SSE$$, the error sum of squares.

Here we utilize the property that the treatment sum of squares plus the error sum of squares equals the total sum of squares. Hence, $$SSE = SS(Total) - SST = 45.349 - 27.897 = 17.45 \, .$$

Step 5: Compute $$MST$$, $$MSE$$, and $$F$$ STEP 5 Compute $$MST$$, $$MSE$$, and their ratio, $$F$$.

$$MST$$ is the mean square of treatments, $$MSE$$ is the mean square of error ($$MSE$$ is also frequently denoted by $$\hat{\sigma}_e^2$$). $$MST = \frac{SST}{k-1} = \frac{27.897}{2} = 13.949$$ $$MSE = \frac{SSE}{N-k} = \frac{17.452}{12} = 1.454$$ where $$N$$ is the total number of observations and $$k$$ is the number of treatments. Finally, compute $$F$$ as $$F = \frac{MST}{MSE} = 9.59 \, .$$ That is it. These numbers are the quantities that are assembled in the ANOVA table that was shown previously. 