Free tool · Sample size
Sample size calculator for comparing two means
Quick answer
To compare a continuous outcome (e.g. blood pressure, pain score, length of stay) between two groups, use n per group = 2 × (Zα + Zβ)² × σ² / Δ². With σ = 10, a clinically important difference Δ = 5, 95% confidence and 80% power, you need 63 per group, or 70 per group after allowing 10% drop-out.
Choosing Δ and σ
- Δ (difference): the smallest difference that would change clinical practice, not the biggest difference you hope to see. A larger Δ gives a smaller sample, which is why examiners check that it is clinically justified and referenced.
- σ (standard deviation): take it from a previous study using the same measurement in a similar population. If two SDs are reported, use the larger one or a pooled SD. A short pilot (10–15 patients) can also give an estimate.
- Power: 80% is the usual minimum; 90% is stronger but needs about 34% more participants (85 instead of 63 per group in the example above).
Worked example
Comparing post-operative pain (VAS 0–100) between two analgesic regimens. A previous study reported SD = 10; a 5-point difference is considered clinically important.
n = 2 × (1.96 + 0.84)² × 10² / 5² = 62.8 ≈ 63 per group. With 10% drop-out: 63 ÷ 0.9 → 70 per group, 140 in total.
When this formula is not enough
- Skewed outcomes (e.g. hospital stay): many statisticians add about 15% when the analysis will use the Mann–Whitney U test.
- Paired designs (before–after in the same patients) use the SD of the differences and need fewer participants.
- More than two groups (ANOVA) or unequal group sizes need a different calculation.
Not sure which test your analysis will use? Try Which statistical test should I use?
Frequently asked questions
Where do I find the standard deviation?
From a published study that measured the same outcome the same way, ideally in a similar population. Cite it in your synopsis. If none exists, run a small pilot and say so.
Is 80% power enough for an MD thesis?
Yes, 80% power with a two-sided α of 0.05 is the accepted minimum for most thesis studies. Use 90% if your guide or IEC asks for it, or if a missed effect would be costly.
What if I cannot recruit the calculated number?
Discuss it before submitting the synopsis: lengthen the recruitment window, add a centre, choose a more common outcome, or change the design. Recruiting far fewer than planned weakens the thesis and is a common viva question.
Written and reviewed by the Research Wing mentor team. Last updated 30 November 2026.