Meaning and conditions
Assume two independent equally sized groups with a common positive planning SD.δ is a prespecified positive absolute difference. The calculator fixes two-sided α=0.05 and target power 0.8 as a normal approximation, not an exact t analysis or arbitrary design adjustment.[1][2]
The two-sample t-test addresses later analysis. A confidence interval for a mean describes observed precision, whereas sample variance provides a data-based estimate of spread.[1][2]
Derivation and relations
Combine the variance of two independent sample means with the critical test threshold and desired separation under a specific alternative.[1][2]
- Specify two independent equally sized groups, a common planning SD σ and a relevant absolute mean difference δ>0. Units of σ and δ must match.
- With n observations per group, the difference has SE=σ√(2/n) under this model. The positive critical normal threshold for a two-sided test isz1−α/2.
- The common planning approximation sets δ/SE≈z1−α/2+z1−β. It neglects the small rejection contribution in the direction opposite the assumed effect.
- Solve for n*=2σ2(z1−α/2+z1−β)2/δ2. Round up per group and calculate N=2⌈n*⌉. Final t planning, attrition and design effects require additional steps.
See the model
Smaller differences require larger samples
Free with a Quanta account. Your download stays ready after registration.
Two complete worked examples
Two groups targeting a difference of five
- Given
- Fictional planning:σ=10,δ=5 in the same response unit, two-sided α=0.05 and power 0.8.
- Find
- Find unrounded and required integer counts per group and in total.
Use z0.975≈1.95996398454andz0.8≈0.84162123357.
Insert σ and δ.
Round the per-group value up before doubling.
Result: Approximate planning requires 63 subjects per group,126 total, before additional design or attrition adjustments.
Check: The standardized target difference δ/σ=0.5 is dimensionless.63 is not the total sample size.
A different spread and target difference
- Given
- Fictionally σ=4 and δ=3, again two-sided α=0.05 and power 0.8.
- Find
- Calculate another normal approximation with a different effect-to-spread ratio.
The ratio is σ/δ=4/3.
Round the required per-group observation count upward.
Result: 28 subjects per group, or 56 in total, under the stated approximation.
Check: With smaller groups, differences from actual t-based planning deserve particular scrutiny; the calculator explicitly names its z approximation.
Recall the method later with the formula’s flashcards.
11 flashcards · English materials
Already have an account? Sign in for flashcardsAvailable from Essential. A ready-made formula set, no AI credits required. Article exercises are not all included.
Units, interpretation and limits
σandδ must share the same physical or scientific unit; their ratio is dimensionless. This bounded calculator expects both numbers on the same normalized response scale.[1][2]
Aδof0 does not permit finite sample size under this formula. Uncertain spread assumptions, clusters, unequal groups and informative attrition need separate consideration; the calculated number is not a guarantee of study success.[1][2]
Five exercises with distinct learning goals
Calculate · Foundation
σ=8,δ=4, two-sided α=0.05, power 0.8: how many subjects per group does the z approximation give?
Show hint
σ/δequals2 as in the first example.
Learning goal: Compare the same standardized target
Show solution and calculation
n*=2·22·(1.95996398454+0.84162123357)2≈62.791038.
Thus n=63 per group and N=126 total.
The same standardized target effect gives the same planning value under the same assumptions.
Rearrange · Application
Rearrange the unrounded planning formula for δ. Which positive root represents an absolute difference?
Show hint
δwas defined as positive.
Learning goal: Rearrange for a target difference
Show solution and calculation
δ=σ(z1−α/2+z1−β)√(2/n*).
The positive root matches an absolute target difference.
An integer n chosen by rounding up can then be assessed within this approximation; the inverse is not an exact t-power calculation.
Interpret · Application
Does power 0.8 mean the null hypothesis has an 80% probability of being false?
Show hint
Power assumes a particular alternative.
Learning goal: Do not confuse power with result probability
Show solution and calculation
No.
Power is the probability of rejecting the null under the specified true difference and model assumptions.
It is not a posterior probability that a hypothesis is false, and does not automatically apply to every possible difference.
Error analysis · Application
A plan uses n*=62.791 and proposes 63 subjects total for two equal groups. What is missing?
Show hint
n*is defined per group.
Learning goal: Separate per-group and total count
Show solution and calculation
First round up to 63 per group, then double: N=126.63 total would nearly halve the planned observation count.
Attrition or other design adjustments require separate treatment, rather than redefining n as total count.
Transfer · Challenge
You need 63 analyzable subjects per group. Plan recruitment per group assuming 90% analyzability.
Show hint
Divide target count by 0.9 and round up.
Learning goal: Add an attrition allowance transparently
Show solution and calculation
Recruitment=⌈63/0.9⌉=70 per group, or 140 total.
This is an extra planning assumption, not a correction for informative dropout.
If missingness depends on group or outcome, more recruitment alone cannot remove bias.
Check your understanding with the formula’s reference test.
8 test questions · English materials
Already have an account? Sign in for the testAvailable from Essential. A ready-made formula set, no AI credits required. Article exercises are not all included.
Sources for this explanation
Quanta · Updated November 9, 2026
- Charles J. Krebs: Sample Size Determination and Statistical Power, chapter 7, section 7.1.2
- R stats: Power calculations for one and two sample t tests
Editorial responsibility: Quanta Study editorial team
Review scope
This explanation, 2 worked examples and 5 exercises are available in German and English. Structure, source references and mathematical notation undergo automated checks. Calculations, model assumptions and both language versions receive a separate AI review.
An independent, named human subject review has not yet been documented. Our exercise numbers are worked examples, rather than measurements published by the cited sources.
Editorial responsibility, sources and methodsChange history
- Added a full article with explicit validity conditions, two authored examples, five checked exercises and an original native data graphic.
Cite this reference page
Quanta. Sample size per group for two means. Updated November 9, 2026. https://quanta-study.de/en/formula-sheet/stichprobengroesse-zwei-mittelwerte
When citing a specific scientific statement, also cite the specialist source linked to that statement.