Tutorials › VEE Mathematical Statistics › How Mean Differences Affect the F Ratio

VEE Mathematical Statistics · One-Way Analysis of Variance · Tutorial 807 of 880

How Mean Differences Affect the F Ratio

Learn how to measure the separation of group means, predict its effect on the ANOVA F ratio, and avoid mistakes with weighting and within-group variation.

Intermediate 10 min read

What You'll Learn

  • Calculate the weighted grand mean and between-group sum of squares from group summaries
  • Explain why scaling group-mean deviations scales between-group variation by the square of that factor
  • Determine how changing group means affects the F ratio when within-group variation is fixed
  • Distinguish mean separation from a common shift of every group mean
  • Recognize why unequal group sizes require a weighted grand mean
  • Interpret the limitations of comparing F ratios across changing samples

Why Group-Mean Separation Matters

In a one-way analysis of variance, the F statistic compares variation among the sample group means with variation among observations within their groups. If the group means spread farther apart while group sizes and within-group variation remain unchanged, the between-group part of that comparison increases. This is why greater separation can produce a larger F ratio.

The important qualification is what stays fixed. The F ratio also depends on within-group variation, sample sizes, and the placement of all the group means relative to their weighted grand mean. A single pairwise difference does not, by itself, determine the F statistic.

Definition: For \(k\) groups, let \(n_j\) be the size of group \(j\), \(\bar{x}_j\) its sample mean, and \(N=\sum_{j=1}^k n_j\) the total sample size. The weighted grand mean is \(\bar{x}_{..}=\sum_{j=1}^k n_j\bar{x}_j/N\). The between-group sum of squares is \(SS_B=\sum_{j=1}^k n_j(\bar{x}_j-\bar{x}_{..})^2\). The within-group sum of squares is \(SS_E=\sum_{j=1}^k\sum_{i=1}^{n_j}(x_{ij}-\bar{x}_j)^2\).

For the usual one-way ANOVA F ratio, \(df_B=k-1\) and \(df_E=N-k\), so \(MS_B=SS_B/(k-1)\), \(MS_E=SS_E/(N-k)\), and \(F=MS_B/MS_E\). The sums of squares describe the observed data; the usual inferential interpretation of the F statistic assumes independent observations from normal populations with a common variance.

Model: For an inferential one-way fixed-effects ANOVA, observations in group \(j\) are modeled as independent \(N(\mu_j,\sigma^2)\) random variables, with group-specific means \(\mu_j\) and one common variance \(\sigma^2>0\). The null hypothesis sets all \(\mu_j\) equal. The calculations below use the stated sample summaries; where an F ratio is interpreted inferentially, this normal, independent, equal-variance model is assumed. Interest rates and mortality assumptions do not apply to these statistical examples.

How Separation Changes the Between-Group Sum of Squares

The contribution of each group to \(SS_B\) is its sample size multiplied by the squared distance from that group’s mean to the weighted grand mean. The square matters: doubling every group mean’s deviation from the grand mean multiplies \(SS_B\) by four, not by two.

A common shift is different. Adding the same constant to every observation adds that constant to every group mean and to the grand mean, leaving each difference \(\bar{x}_j-\bar{x}_{..}\) unchanged. Thus, a common shift does not change \(SS_B\) or the F ratio.

Key result: If group sizes stay fixed and each group mean is changed to \(\bar{x}_j^*=\bar{x}_{..}+c(\bar{x}_j-\bar{x}_{..})\), then the new weighted grand mean remains \(\bar{x}_{..}\) and \(SS_B^*=c^2SS_B\). If \(SS_E\) also stays fixed, \(F^*=c^2F\). This comparison concerns the stated data changes; it does not say that F must increase in every pair of independently collected samples.

Why the Weighted Grand Mean Is the Center

The weighted grand mean is not a bookkeeping convenience. It is the center that minimizes the weighted sum of squared distances from the group means. To see this, write \(\bar{x}_{..}=\sum_j n_j\bar{x}_j/N\). For any proposed center \(a\), expand each difference around \(\bar{x}_{..}\):

$$ \begin{aligned} \sum_{j=1}^k n_j(\bar{x}_j-a)^2 &=\sum_{j=1}^k n_j\big[(\bar{x}_j-\bar{x}_{..})+(\bar{x}_{..}-a)\big]^2\\ &=\sum_{j=1}^k n_j(\bar{x}_j-\bar{x}_{..})^2 +2(\bar{x}_{..}-a)\sum_{j=1}^k n_j(\bar{x}_j-\bar{x}_{..})\\ &\quad+(\bar{x}_{..}-a)^2\sum_{j=1}^k n_j\\ &=SS_B+N(\bar{x}_{..}-a)^2. \end{aligned} $$

The middle term is zero because \(\sum_j n_j(\bar{x}_j-\bar{x}_{..})=0\), by the definition of the weighted grand mean. Since \(N(\bar{x}_{..}-a)^2\geq 0\), the weighted squared distances are smallest at \(a=\bar{x}_{..}\). This also shows why replacing the weighted grand mean by an unweighted average can give the wrong between-group sum of squares when group sizes differ.

Worked Examples

Worked Example: Doubling the Mean Deviations

A hypothetical laboratory compares a measured response from three treatment groups. Each group has four observations, the sample means are 10, 12, and 14 units, and the total within-group sum of squares is 30. Calculate the F ratio, then find the ratio if the group means are changed to 8, 12, and 16 while group sizes and within-group variation stay fixed.

Method and assumptions. Use the one-way ANOVA sums of squares and mean squares. For inferential interpretation, assume independent observations from group \(j\) distributed as \(N(\mu_j,\sigma^2)\), with group-specific means and a common unknown variance. The given values are sample summaries; no interest rate or mortality assumption applies.

Original means. Because the groups have equal sizes, the weighted grand mean is also the ordinary mean:

$$ \bar{x}_{..}=\frac{4(10)+4(12)+4(14)}{12} =\frac{144}{12}=12. $$

The between-group sum of squares is

$$ SS_B=4(10-12)^2+4(12-12)^2+4(14-12)^2 =4(4)+4(0)+4(4)=32. $$

There are \(k=3\) groups and \(N=12\) observations. Therefore, \(df_B=3-1=2\), \(df_E=12-3=9\), \(MS_B=32/2=16\), and \(MS_E=30/9=10/3\). Thus,

$$ F=\frac{16}{10/3}=4.8. $$

Changed means. The new grand mean is \((8+12+16)/3=12\). The deviations from it are \(-4,0,4\), twice the original deviations \(-2,0,2\). Hence \(SS_B=4(16)+4(0)+4(16)=128\), \(MS_B=128/2=64\), and \(MS_E\) remains \(10/3\). The new ratio is \(F=64/(10/3)=19.2\), four times 4.8, as expected when the deviations are doubled.

Check and common mistake avoided. The within-group sum of squares and both degrees of freedom are unchanged, while the between-group sum of squares is multiplied by \(2^2=4\). The F ratio therefore also multiplies by four. Treating a doubling of mean separation as only a doubling of \(SS_B\) would be incorrect because the deviations are squared.

Worked Example: Shrinking Separation With Unequal Group Sizes

A hypothetical materials study has groups of sizes 2, 4, and 6. Their sample means are 5, 8, and 11 units, and \(SS_E=60\). Find the F ratio. Then suppose the means change to 7, 8.5, and 10 while the group sizes and \(SS_E\) stay fixed. Find the new ratio.

Method and assumptions. Use a weighted grand mean because group sizes are unequal, then calculate the two mean squares. For inferential interpretation, assume independent observations from \(N(\mu_j,\sigma^2)\) in group \(j\), with a common variance; the \(\mu_j\) are unknown population means. This hypothetical statistical calculation has no interest rate or mortality assumption.

For the original means, \(N=2+4+6=12\), and the weighted grand mean is

$$ \bar{x}_{..}=\frac{2(5)+4(8)+6(11)}{12} =\frac{10+32+66}{12}=9. $$

The between-group sum of squares is

$$ SS_B=2(5-9)^2+4(8-9)^2+6(11-9)^2 =2(16)+4(1)+6(4)=60. $$

Here \(df_B=3-1=2\) and \(df_E=12-3=9\). Thus \(MS_B=60/2=30\), \(MS_E=60/9=20/3\), and \(F=30/(20/3)=4.5\).

For the changed means, the weighted grand mean is

$$ \bar{x}_{..}^{*}=\frac{2(7)+4(8.5)+6(10)}{12} =\frac{14+34+60}{12}=9. $$

Consequently, \(SS_B^*=2(7-9)^2+4(8.5-9)^2+6(10-9)^2=2(4)+4(0.25)+6(1)=8+1+6=15\). The new mean squares are \(MS_B^*=15/2=7.5\) and \(MS_E=60/9=20/3\), so

$$ F^*=\frac{7.5}{20/3}=\frac{22.5}{20}=1.125. $$

The new deviations from the grand mean are half the original deviations: \((-4,-1,2)\) became \((-2,-0.5,1)\). Therefore \(SS_B\), and hence \(F\), became one quarter as large: \(4.5/4=1.125\).

Check and common mistake avoided. The weighted mean is 9 in both cases, the error mean square stays \(20/3\), and the new F ratio is smaller. Do not use an unweighted average of the three means when the group sizes differ.

Worked Example: Weighting Changes the Apparent Separation

A hypothetical service center compares processing times for groups of sizes 2, 4, and 6. The sample means are 2, 5, and 8 minutes, and \(SS_E=60\). Calculate F correctly, explain the error from using the unweighted mean, and then find F if the mean deviations from the weighted grand mean are multiplied by 1.5 while \(SS_E\) stays fixed.

Method and assumptions. Calculate the weighted center and \(SS_B\), then use the ANOVA degrees of freedom. For inferential interpretation, assume independent group observations distributed as \(N(\mu_j,\sigma^2)\), with unknown group means and common unknown variance. There is no interest rate or mortality assumption in this example.

The total sample size is \(N=12\), and the weighted grand mean is

$$ \bar{x}_{..}=\frac{2(2)+4(5)+6(8)}{12} =\frac{4+20+48}{12}=6. $$

Thus,

$$ SS_B=2(2-6)^2+4(5-6)^2+6(8-6)^2 =2(16)+4(1)+6(4)=60. $$

The degrees of freedom are \(df_B=2\) and \(df_E=12-3=9\). Therefore \(MS_B=60/2=30\), \(MS_E=60/9=20/3\), and \(F=30/(20/3)=4.5\).

The unweighted mean of 2, 5, and 8 is 5, but it is not the grand mean for these data. Incorrectly centering at 5 gives \(2(2-5)^2+4(5-5)^2+6(8-5)^2=18+0+54=72\), rather than 60. This would incorrectly produce \(F=(72/2)/(20/3)=36/(20/3)=5.4\).

If deviations from 6 are multiplied by 1.5, the new means are \(6+1.5(2-6)=0\), \(6+1.5(5-6)=4.5\), and \(6+1.5(8-6)=9\). Their weighted grand mean remains 6, since the weighted deviations still sum to zero. The new between-group sum of squares is \(1.5^2(60)=135\), so \(MS_B^*=135/2=67.5\). With \(MS_E=20/3\), the new ratio is \(F^*=67.5/(20/3)=10.125\).

Check and common mistake avoided. Scaling the deviations by 1.5 multiplies \(SS_B\) and F by \(1.5^2=2.25\); indeed \(4.5(2.25)=10.125\). Using the unweighted mean would miscenter groups that contribute different numbers of observations.

What the F Ratio Does and Does Not Say

For a fixed data set, \(F=MS_B/MS_E\). If group sizes and within-group observations relative to their own means remain fixed, increasing the weighted spread of the group means raises \(SS_B\), and therefore raises F. Alternatively, even with unchanged group means, reducing within-group scatter reduces \(MS_E\) and raises F. The ratio reflects both parts of the comparison, not mean separation alone.

In the one-way fixed-effects model, the expected mean squares also explain the role of genuine population mean differences. Let \(\bar{\mu}_w=\sum_j n_j\mu_j/N\) and \(Q=\sum_j n_j(\mu_j-\bar{\mu}_w)^2\). Under independent normal errors with common variance \(\sigma^2\), the expected mean squares are

$$ E(MS_E)=\sigma^2,\qquad E(MS_B)=\sigma^2+\frac{Q}{k-1}. $$

When all population means are equal, \(Q=0\); when they differ, \(Q>0\). Thus greater weighted population-mean separation raises the expected between-group mean square relative to the error mean square. This is an expectation statement, not a guarantee that every realized F ratio will rise: sampling variation can change both observed mean squares. Comparisons that change the sample, its group sizes, or its within-group variation must be interpreted with care.

Key takeaway: With group sizes and within-group variation fixed, F increases with the weighted squared spread of the sample means. A common shift of all means has no effect; multiplying all deviations from the weighted grand mean by \(c\) multiplies F by \(c^2\). The weighted center and the within-group mean square are essential to that conclusion.

Check Your Understanding

For each problem, use the weighted grand mean when needed and keep track of both mean squares.

  1. Three groups each contain 5 observations, their sample means are 20, 22, and 24, and \(SS_E=36\). Find the one-way ANOVA F ratio. (Answer: \(F=6.6667\).)
  2. Groups have sizes 2, 3, and 5, sample means 3, 6, and 9, and \(SS_E=64\). Find the weighted grand mean, \(SS_B\), and F. (Answer: weighted grand mean \(=6.9\), \(SS_B=54.9\), \(F=3.0023\).)
  3. Three groups each have 3 observations, with means 1, 4, and 7 and \(SS_E=36\). If 10 is added to every observation, what is the new F ratio? (Answer: \(F=4.5000\), unchanged.)
  4. Groups have sizes 2, 4, and 6, with means 5, 8, and 11 and \(SS_E=54\). Find F using the correct center. (Answer: \(F=5.0000\).)
  5. For a fixed set of group sizes and fixed \(SS_E\), the group means’ deviations from their weighted grand mean are all multiplied by 0.5. If the original F ratio is 8, what is the new F ratio? (Answer: \(F=2\).)
Clinical Biostats