The University of Hong Kong · FACULTY OF STATISTICS

MEDD8815 Chap.8 One-Way and Two-Way Analysis of Variance

- one subject, every graph, every model, every mark
8 Chapters6-page Bible
Our own words - no uploaded lecturer files
Updated for this semester
Chapter 8 of 8 · MEDD8815

One-Way and Two-Way Analysis of Variance

Comparing several means at once

The final session generalises the two-sample comparison to several groups. Analysis of variance judges whether sample means differ by more than the variation inside the groups would lead you to expect.

Running a t test for every pair would inflate the chance of a false alarm, so ANOVA replaces them with one overall F test, followed by an adjusted analysis of which means differ.

The one-way model and its table

The chapter sets out the model, the null hypothesis that every group shares one population mean, and the conditions: independent random samples, Normal populations and a common standard deviation, checked with the rule that the largest sample standard deviation should be no more than twice the smallest.

It builds the ANOVA table from group summaries on an AskSia-authored three-group data set, showing how the total sum of squares divides into a between-group part and a within-group part, and how their mean squares form the F statistic.

Contrasts and multiple comparisons

A significant F test says the means are not all equal but not which ones differ.

Questions fixed in advance are answered with contrasts, combinations of means whose coefficients sum to zero, tested with t on the error degrees of freedom and adjusted with Bonferroni when there are several. When no pattern was specified, pairwise methods such as Tukey and Scheffe control the familywise error rate.

The chapter works both and shows the SPSS Contrasts and Post Hoc routes.

Two factors and interaction

A two-way design crosses two factors, which is more efficient than separate studies and is the only way to see an interaction.

The chapter reads a profile plot in which the lines are not parallel, fills and reads a two-way ANOVA table, and follows the slides' cautions: plot the cell means, read the interaction row first, and interpret cell means when interaction is present. It also shows that the three tests of a balanced two-by-two design reappear as three contrasts in a one-way analysis of its four cells.

In this chapter

What this chapter covers

  • 01

    The idea of analysis of variance

  • 02

    The one-way ANOVA model and its conditions

  • 03

    The F statistic and the ANOVA table

  • 04

    Why many t tests inflate false alarms

  • 05

    Planned contrasts and their t tests

  • 06

    Bonferroni, Tukey and Scheffe comparisons

  • 07

    Two-way designs, main effects and interaction

  • 08

    Reading the two-way ANOVA table and profile plot

Worked example · free

Complete an ANOVA table from partial output

Q [5 marks]. AskSia-authored practice. Four teaching approaches are compared with 10 pupils in each. The output shows a between-groups sum of squares of 96 and a within-groups sum of squares of 432. Complete the degrees of freedom, mean squares and F, and state the conclusion at the 5 per cent level given that the 5 per cent critical value of F(3, 36) is about 2.87. The marks shown are an AskSia study allocation and are not the University's marking scheme.
Three AskSia-authored groups of eight.Three AskSia-authored groups of eight. The audio group sits well above the grand mean, the no-feedback group well below, and the spreads are similar.Group means with one SD either side, and the grand mean5055606570Writing scoregrand mean 62.00Written61.5Audio68None56.5
Three AskSia-authored groups of eight. The audio group sits well above the grand mean, the no-feedback group well below, and the spreads are similar.
  • 1Find the three degrees of freedom from I and N.
  • 2Compute both mean squares and F.
  • 2Compare with the critical value and state what follows next.
With I = 4 groups and N = 40 pupils, the degrees of freedom are 3 for groups, 36 for error and 39 in total. MSG = 96/3 = 32 and MSE = 432/36 = 12, so F = 32/12 = 2.67. That is below the 5 per cent critical value of about 2.87, so the P-value exceeds 0.05 and we do not reject the hypothesis that the four mean scores are equal. Because the overall test is not significant, no post-hoc pairwise comparisons should be run; a planned contrast fixed in advance could still be examined.
Sia tip — Mean squares divide each sum of squares by its own degrees of freedom; F is the ratio of the two mean squares, never of the two sums of squares.
Glossary

Key terms

Analysis of Variance
A method for comparing several population means by comparing the variation among sample means with the variation within the samples.
Mean Square Error
The within-group variance estimate in ANOVA, the error sum of squares divided by N minus I; its square root is the pooled standard deviation.
F Statistic
The ratio of the between-group mean square to the within-group mean square, compared with an F distribution to test equality of means.
Contrast
A combination of population means whose coefficients add to zero, used to answer a question about the means that was fixed before the data were seen.
Familywise Error Rate
The probability of at least one false rejection across a whole set of tests, which grows as more unadjusted tests are run.
Bonferroni Procedure
An adjustment for k tests that multiplies each P-value by k, capped at 1, so the familywise error rate stays at or below alpha.
Interaction
A situation in a two-way design in which the effect of one factor depends on the level of the other, shown by non-parallel lines in a profile plot.
FAQ

One-Way and Two-Way Analysis of Variance FAQ

Why not just run a t test for each pair of groups?

Each test carries its own chance of a false alarm, so running many of them makes at least one spurious significant result increasingly likely. ANOVA tests all the means with one F test, and follow-up comparisons use methods that adjust for how many comparisons are made.

When do I use a contrast rather than Tukey or Scheffe?

Use a contrast for a question you fixed before the data were collected, such as whether any feedback beats none. Use Tukey to compare every pair after a significant F, and Scheffe when you want protection across any contrast, including ones suggested by the data.

What should I do when the interaction is significant?

Describe the cell means rather than the main effects. The main effect of a factor averages over the levels of the other factor, and when the effect changes from one level to another that average can hide or distort what actually happens in each combination.

Study strategy

Assessment move

Build one ANOVA table completely by hand from group means, standard deviations and sizes, then check it in SPSS One-Way ANOVA. Next, draw a profile plot for a two-way example and say in one sentence whether the lines suggest interaction before reading the table. Both skills are what the final homework and quiz material rest on.

Working through One-Way and Two-Way Analysis of Variance in MEDD8815? Sia is AskSia’s AI Statistics tutor — ask any MEDD8815 One-Way and Two-Way Analysis of Variance question and get a clear, step-by-step explanation grounded in how MEDD8815 is taught and assessed. Read this chapter free, then take your hardest questions to Sia.

A+Everything unlocked
Unlocks this Bible + all 26 of your The University of Hong Kong subjects - and 1,000+ Bibles across every Australian university.
Sia - your MEDD8815 tutor, unlimited, worked the way the exam marks it
The full 6-page Bible + practice bank with worked solutions
Chrome extension - sync your LMS so Sia knows your deadlines
Bilingual EN / Chinese on every Bible and every Sia answer
$0.99 Trial
30-day money-back · cancel in one tap · how it works