Uploaded by ADRIAN NATHANIEL Castillo

ANOVA - CASTILLO, Adrian Nathaniel D

advertisement
To illustrate the ANOVA computation using the five-step approach with the use of ANOVA
table. The ANOVA table breaks down data components into variation between treatments and
residual variation.
The ANOVA table is set up as follows:
Source of Variation
Sums of Squares (SS)
Degrees of Freedom (df)
Between Treatments
k-1
Error (or Residual)
N-k
Total
N-1
Mean Squares (MS)
F
Where;



X = individual observation,
= sample mean of the jth treatment (or group),
= overall sample mean,

k = the number of treatments or independent comparison groups, and

N = total number of observations or total sample size.
The ANOVA table above is organized as follows.

"Sums of Squares (SS)" - the between treatment sums of squares is
and is computed by summing the squared differences between each treatment (or
group) mean and the overall mean. The squared differences are weighted by the
sample sizes per group (nj). The sums of squares within groups is:
and is computed by summing the squared differences between each observation and
its group mean (i.e., the squared differences between each observation in group 1 and
the group 1 mean, the squared differences between each observation in group 2 and
the group 2 mean, and so on). The “double summation” indicates summation of the
squared differences within each treatment and then summation of these totals across
treatments to produce a single value. The total sums of squares is:
and is computed by summing the squared differences between each observation and
the overall sample mean. In an ANOVA, data are organized by comparison or treatment
groups. If all of the data were pooled into a single sample, SST would reflect the
numerator of the sample variance computed on the pooled or total sample. SST does
not figure into the F statistic directly. However, SST = SSB + SSE, thus if two sums of squares
are known, the third can be computed from the other two.

Degrees of Freedom - the between treatment degrees of freedom is df1 = k-1. The error
degrees of freedom is df2 = N - k. The total degrees of freedom is N-1 (and it is also true that
(k-1) + (N-k) = N-1).

Mean Squares (MS) - are computed by dividing sums of squares (SS) by degrees of
freedom (df), row by row.
Specifically, MSB=SSB/(k-1) and MSE=SSE/(N-k). Dividing SST/(N-1) produces the variance
of the total sample. The F statistic is in the rightmost column of the ANOVA table and is
computed by taking the ratio of MSB/MSE.
Example:
The best way to discuss ANOVA computation is through providing example;
“The stress level of 5 employees during normal days of work, announced layoffs and during
layoffs.”
Sample data gathered;
Normal
2
3
7
2
6
Announced
layoffs
10
8
7
5
10
During
layoffs
10
13
14
13
15
We will run the ANOVA using the five-step approach.

Step 1 Set up hypotheses and determine level of significance
H0: There is no difference on the levels of stress of employees in relation to layoffs. (μ1 =
μ2 = μ3 = μ4)
H1: There is a significant difference on the levels of stress of employees in relation to
layoffs.

Step 2 Select the appropriate test statistic
The test statistic is the F statistic for ANOVA, F=MSB/MSE.
α=0.05

Step 3 Set up decision rule
The appropriate critical value can be found in a table of probabilities for the F distribution
(see figure 1.1). In order to determine the critical value of F we need degrees of freedom,
df1=k-1 and df2=N-k.
In this example, df1=k-1 = 3-1=2 and df2=N-k =15-3=12
The critical value is 3.89 and the decision rule is as follows: Reject H0 if F > 3.89

Step 4. Compute the test statistic.
To organize our computations, we complete the ANOVA table. In order to compute the
sums of squares we must first compute the sample means for each group and the overall
mean based on the total sample.
After we create a table, we may already start computing for SSW (Sums of the Squares
Within Groups)
SSW =
Group 1
2
3
7
2
6
x-x̄
-2
-1
3
-2
2
(x-x̄ )2
4
1
9
4
4
Group 2
10
8
7
5
10
x-x̄
2
0
-1
-3
2
(x-x̄ )2
4
0
1
9
4
Group 3
10
13
14
13
15
x-x̄
-3
0
1
0
2
(x-x̄ )2
9
0
1
0
4
20
4
0
22
40
8
0
18
65
13
0
14
SSW = 22+18+14= 54
Next we compute for SSB (Sum of the Squares Between).
SSB =
If we pool all N=15 observations, the overall mean is
We can now compute
SSB =
So, in this case:
SSB = 5(4-8.33)2+5(8-8.33)2+5(13-8.33)2
SSB = 93.74 + 0.54 + 109.05
SSB = 203.33
Next compute for MSB & MSW and F-Ratio
MSB=SSB/df1 and MSW=SSW/df2
MSB = 203.33/2 = 101.67
MSW = 54/12 = 4.5
F = MSB/MSW = 22.59
We can now complete the ANOVA Table;
= 8.33
Source of
Variation
SSB
SSW
Total (SST)

Sums of
Squares
Degrees of
Freedom
(SS)
203.33
54
257.33
(df)
2
12
14
Means Squares
F
(MS)
101.67
4.5
22.59
Step 5. Conclusion
We reject the null hypothesis because 22.59 is > 3.89. Hence, there is a significant difference on
the stress level of employees in relation to layoffs.
Figure 1.1: table of probabilities for the F distribution
Download