wanna mathMath ain't scary (not anymore)
4-Tier Textbook Index • Vol → Mod → Ch → Lab

Engineering Mathematics Volumes I–VI

6 Volumes • 20 Modules • 85 ChaptersFull Matrix →
4-Tier Statistics Index • Vol S → Mod → Ch → Lab

Interactive Statistics (S.1–S.6)

6 Modules • 18 ChaptersStatistics Index →
CHAPTER S.5.3 • 2DPublished Interactive Labs~30 min study

One-Way ANOVA: Between vs. Within Variance & Multiple Comparisons

Test whether 3+ group means differ by comparing signal variance between groups against background noise variance within groups.

Engineering & Physical Application Context

Multi-variant design optimization, agricultural yield trials, and material alloy strength comparisons.

Governing Mathematical Formulation
∑i,j(yij−yˉ)2=∑ini(yˉi−yˉ)2+∑i,j(yij−yˉi)2\sum_{i,j}(y_{ij} - \bar{y})^2 = \sum_i n_i(\bar{y}_i - \bar{y})^2 + \sum_{i,j}(y_{ij} - \bar{y}_i)^2
Volume S • Module S.51 Interactive Lab(s)

The Question You Should Ask

Why does running many separate tt-tests inflate false alarms 1−(1−α)m1 - (1-\alpha)^m—and how does ANOVA test equality of kk group means in a single F=MSB/MSWF = \text{MSB}/\text{MSW} ratio?

In Simple Words & Math

Pythagorean orthogonality splits Total Sum of Squares cleanly into Between-Group signal and Within-Group noise: SST=SSB+SSW\text{SST} = \text{SSB} + \text{SSW}.

Dividing each sum by its degrees of freedom creates Mean Squares whose ratio F=MSB/MSWF = \text{MSB}/\text{MSW} stays near 11 under equal means and spikes cleanly when at least one treatment differs.

4-Step Pedagogical Chapter Rhythm • Geometric Intuition First
Ch. S.5.3
STEP 1 • GEOMETRIC QUESTION

Why shouldn't we just run ten separate t-tests to compare 5 drugs—and why is a test of means literally named 'Analysis of Variance'?

STEP 2 • INTERACTIVE LAB EXPLORATION

Drag group means apart (increasing MSB) and widen within-group noise (increasing MSW) to watch SST = SSB + SSW, F = MSB/MSW, and the family-wise false-positive meter.

STEP 3 • SYMBOLIC FORMALIZATION
SST=SSB+SSW,F=MSBMSW=SSB/(k−1)SSW/(N−k)\text{SST} = \text{SSB} + \text{SSW}, \qquad F = \frac{\text{MSB}}{\text{MSW}} = \frac{\text{SSB}/(k-1)}{\text{SSW}/(N-k)}
STEP 4 • EDGE CASES & NEXT BRIDGE

ANOVA detects group differences across discrete treatments; Module S.6 models continuous predictors with Regression, Regularization, and Bayesian updating.

Interactive Laboratories in Chapter S.5.3
FIRST-TIMER GUIDE • SIGNAL-TO-NOISE ACROSS 3+ GROUPS

One-Way ANOVA: Testing Many Group Means by Splitting Total Variation into Signal vs. Noise

Wait—why is a test for means called Analysis of Variance (ANOVA)? Imagine 3 study groups taking the same exam. Even if every group learns identically, dots bounce up and down inside each group (that's background Within-Group Noise). If the study methods actually differ, the group centers pull far apart from the overall average (that's Between-Group Signal). Ronald Fisher realized you can compare all groups in one single shot by taking the ratio F=Signal Variance/Noise VarianceF = \text{Signal Variance} / \text{Noise Variance}—dodging the false-alarm explosion you'd get from running lots of separate tt-tests!

Initializing Interactive Laboratory
LOADING MODULE

Preparing interactive canvas & numerical solver…

wanna math drafting viewport

The Variance Identity, Mean Squares & Multiple-Comparison Protection

1. PYTHAGOREAN VARIANCE SPLIT
SST=SSB+SSW\text{SST} = \text{SSB} + \text{SSW}

Every point's total distance from the grand mean splits cleanly: (ygi−yˉ)=(yˉg−yˉ)+(ygi−yˉg)(y_{gi} - \bar{y}) = (\bar{y}_g - \bar{y}) + (y_{gi} - \bar{y}_g). Squaring and summing cancels the cross-term cleanly to zero!

2. FISHER'S F-RATIO & η² EFFECT SIZE
F=SSB/(k−1)SSW/(N−k)=MSBMSWF = \frac{\text{SSB} / (k - 1)}{\text{SSW} / (N - k)} = \frac{\text{MSB}}{\text{MSW}}

Under H0H_0, both MSB\text{MSB} and MSW\text{MSW} estimate the exact same σ2\sigma^2, so F≈1F \approx 1. Meanwhile, η2=SSB/SST\eta^2 = \text{SSB}/\text{SST} tells you what fraction of total score variance the groups explain!

3. TINY WORKED ANOVA CHECK

Suppose k=3k = 3 groups (N=30N = 30) give SSB=180\text{SSB} = 180 and SSW=540\text{SSW} = 540:

F=180/2540/27=9020=4.50    (p≈0.020)F = \frac{180 / 2}{540 / 27} = \frac{90}{20} = 4.50 \;\;(p \approx 0.020)

And η2=180/(180+540)=25%\eta^2 = 180 / (180 + 540) = 25\% of total score variation comes from group choice!

TRAP • ANOVA ONLY SAYS “AT LEAST ONE DIFFERS”

A tiny ANOVA pp-value does NOT tell you which pair differs (A vs. B, or C vs. the rest)! Once FF rejects H0H_0, run Tukey HSD or Bonferroni (α/m\alpha/m) post-hoc comparisons to pinpoint the culprit without false alarms.

BRIDGE TO MODULE S.6 • LINEAR REGRESSION IS CONTINUOUS ANOVA!

Notice η2=SSB/SST\eta^2 = \text{SSB}/\text{SST}? In Module S.6 (S.6.1), when group categories turn into a continuous predictor xx, SST=SSR+SSE\text{SST} = \text{SSR} + \text{SSE} turns straight into Ordinary Least Squares Regression & R2R^2!

Multi-Group Variance Analysis • Ch. S.5.3

Orthogonal Proof of SST = SSB + SSW, Expectation of MSB/MSW & Family-Wise Control

Open ANOVA Table →
1. CROSS-TERM CANCELLATION PROOF
(yij−yˉ)=(yˉi−yˉ)+(yij−yˉi),∑j=1ni(yij−yˉi)=0(y_{ij}-\bar{y}) = (\bar{y}_i-\bar{y}) + (y_{ij}-\bar{y}_i), \qquad \sum_{j=1}^{n_i}(y_{ij}-\bar{y}_i)=0

Squaring and summing eliminates every cross-product identically because residuals within each group sum to zero, decomposing total scatter cleanly into SST=SSB+SSW\text{SST} = \text{SSB} + \text{SSW}.

2. WHY E[MSB] ISOLATES TREATMENT SIGNAL
E[MSW]=σ2,E[MSB]=σ2+1k−1∑i=1kni(μi−μˉ)2\mathbb{E}[\text{MSW}] = \sigma^2, \qquad \mathbb{E}[\text{MSB}] = \sigma^2 + \frac{1}{k-1}\sum_{i=1}^{k} n_i(\mu_i - \bar{\mu})^2

Because both mean squares estimate σ2\sigma^2 when all group means match (μ1=⋯=μk\mu_1=\dots=\mu_k), the ratio F=MSB/MSWF = \text{MSB}/\text{MSW} hovers near 11 under H0H_0 and spikes only when means diverge.

3. MULTIPLE TESTING & POST-HOC GUARD
P(≥1 False Positive)=1−(1−α)(k2)P(\ge 1 \text{ False Positive}) = 1 - (1 - \alpha)^{\binom{k}{2}}

Running all (52)=10\binom{5}{2}=10 pairwise tt-tests at α=0.05\alpha=0.05 inflates false alarms to 40.1%40.1\%! Use the omnibus FF-test first, then Bonferroni or Tukey HSD for pairwise differences.

Chapter S.5.3 Laboratory Specifications

1 Interactive Lab(s)
LAB S.5.3.1Component: AnovaBetweenWithinLab

ANOVA Between-vs-Within Variance & Multiple Testing Lab

Manipulate group separation and within-group jitter to decompose SST = SSB + SSW and see why multiple t-tests inflate α.

F=Between-Group VarianceWithin-Group VarianceF = \frac{\text{Between-Group Variance}}{\text{Within-Group Variance}}