Clinical Trials · RM-ANOVA
Sample Size for Repeated-Measures ANOVA
Calculate the minimum balanced sample size required for a between-subject factor, within-subject factor, or group × measurement interaction in a univariate repeated-measures ANOVA.
4. Results
Enter the repeated-measures planning assumptions and select Calculate.
Suggested sample-size wording
Formula, assumptions, limitations, and methodological note
Example clinical scenario
A randomized diabetes trial measures HbA1c at baseline, three months, and six months and tests whether the mean pattern over time differs between intervention and control groups.
Formula and methodological note
Use this calculator when planning a study with continuous, approximately normally distributed outcomes measured repeatedly in the same participants and equal allocation across two or more groups. The result is the number of participants expected to provide complete analysable repeated measurements; the recruitment target is inflated separately for expected dropout/non-response.
The calculator uses the univariate repeated-measures ANOVA framework and evaluates power from the upper tail of a noncentral F distribution. It searches only balanced total sample sizes divisible by the number of groups.
Raw-scale input: the selected effect's Cohen's f is calculated as the root mean square of its expected-mean effect components divided by the common SD. For an interaction, each component is cell mean − group mean − measurement mean + grand mean.
Between-subject factor: λ = Nf²m / [1 + (m − 1)ρ]; df1 = g − 1; df2 = N − g.
Within-subject factor: λ = Nf²mε / (1 − ρ); df1 = (m − 1)ε; df2 = (N − g)(m − 1)ε.
Group × measurement interaction: λ = Nf²mε / (1 − ρ); df1 = (g − 1)(m − 1)ε; df2 = (N − g)(m − 1)ε.
Critical F = central F quantile at 1 − α; power = P[F noncentral(df1, df2, λ) > critical F].
Adjusted sample per group = ceiling[(N / g) / (1 − dropout proportion)].
- Equal group allocation and a common correlation structure among repeated measurements are assumed.
- Epsilon is required for within-subject and interaction analyses to account for departures from sphericity.
- Outcomes should be continuous and approximately normally distributed.
- The analysable sample assumes complete repeated measurements.
- The calculator does not directly provide power for mixed-effects models, GEE, binary outcomes, unequal measurement schedules, informative missingness, heterogeneous covariance structures, or cluster-randomized designs.
Cohen's f or the expected means should represent the smallest effect considered important by the researcher. The common SD, within-participant correlation, and epsilon should come from credible pilot data or closely comparable literature. Because the sample size can be sensitive to these inputs, consider plausible alternative assumptions during protocol development.
Expected-means input is an alternative way to obtain Cohen's f, not a different power method. For between-subject and within-subject effects, enter the appropriate marginal means. For an interaction, enter every group-by-measurement mean; a constant or average treatment difference across follow-ups is not a group × measurement interaction.
Technical results
Minimum balanced sample verification
Method references
- Faul F, Erdfelder E, Lang AG, Buchner A. G*Power 3: A flexible statistical power analysis program for the social, behavioral, and biomedical sciences. Behavior Research Methods. 2007;39:175–191. doi:10.3758/BF03193146.
- Cohen J. Statistical Power Analysis for the Behavioral Sciences. 2nd ed. Lawrence Erlbaum Associates; 1988.
- Muller KE, Barton CN. Approximate power for repeated-measures ANOVA lacking sphericity. Journal of the American Statistical Association. 1989;84:549–555.
- Geisser S, Greenhouse SW. An extension of Box’s results on the use of the F distribution in multivariate analysis. Annals of Mathematical Statistics. 1958;29:885–891.
- Huynh H, Feldt LS. Conditions under which mean square ratios in repeated measurements designs have exact F-distributions. Journal of the American Statistical Association. 1970;65:1582–1589.
Suggested citation
Yaacob, Najib Majdi. “Sample Size for Repeated-Measures ANOVA (RM-ANOVA).” Web calculator. NajibMY, 2026. Accessed July 29, 2026. https://najibmy.netlify.app/tools/sample-size/clinical-complex-study-designs/repeated-measures-anova/.