StudySizer

A Sample Size Calculator

Comprehensive sample size calculator for a wide range of study designs

🚀 Launch StudySizer

Why StudySizer?

This open-source and free web application, hosted on Streamlit, enables researchers, students, and professionals to calculate the required sample size for a wide range of study designs. With a clean, user-friendly interface, the app supports various statistical methods tailored to public health and biomedical research. One of its standout features is that it not only provides the calculated sample size but also displays the relevant formulas and academic references — making it both a practical and educational tool.

Advantages of Using StudySizer

📬 About the Developer

Rajesh Majumder – Statistician, St. John's Research Institute, India

Email: rajeshnbp9051@gmail.com
Blog: rajeshmajumderblog.netlify.app


Understanding Sample Size in Public Health Research: A Practical Guide

“How many people do I need in my study?” If you're planning a public health survey or intervention, this is one of the first — and most important — questions you'll face. And no, the answer is not just “as many as possible.” It’s about balance: between confidence, cost, and the ability to detect meaningful results.

This guide will walk you through what sample size really means, why it matters, and how to calculate it — in plain, practical terms.

What Is Sample Size?

The sample size is simply the number of people or units included in your study. In most public health settings, surveying or testing every person in a population isn’t practical. Instead, we draw a sample — a smaller group meant to represent the whole.

For instance, if you're studying anemia prevalence among schoolchildren in a city, you don’t need to test all 50,000. A carefully calculated sample of a few hundred will likely give you the insights you need.

Why Sample Size Matters

Too small a sample, and you might miss important effects. Too large, and you waste resources. In public health — where time, budget, and ethical considerations matter — getting the sample size right is essential.

A good sample size ensures that your study has enough statistical power to detect a real effect (if there is one), while keeping the margin of error within acceptable limits.

Two Approaches to Sample Size Calculation

1. Precision-Based Sample Size (Descriptive Studies)

This is commonly used in surveys or prevalence studies, where you're estimating a percentage or mean in a population.

n = (Z² × p(1-p)) / d²

Where: Z = Z-score (1.96 for 95% confidence), p = expected prevalence, d = desired margin of error (e.g., 0.05).

Example:

If you expect anemia prevalence to be 40%, want a 5% margin of error, and 95% confidence, you'd need about 369 participants.

2. Effect Size–Based Sample Size (Analytical Studies)

Used in trials or studies comparing groups (e.g., comparing two treatments).

n = [2σ² (Z1−α/2 + Z1−β)²] / Δ²

Where: σ = standard deviation, Δ = expected difference between groups, Z1−α/2 = for confidence level, Z1−β = for power.

Example:

To detect a 1 g/dL difference in hemoglobin between two iron therapies with 80% power and 95% confidence, you'd need about 63 participants per group.

Comparison Table: Precision vs. Effect-Based

Feature Precision-Based Effect Size–Based
Used For Surveys, prevalence studies Comparative trials or analytical studies
Goal Estimate a population parameter Detect a difference between groups
Needs Effect Size? No Yes
Needs Prevalence? Yes No

Tips for Public Health Researchers

Conclusion

Sample size calculation is not just a technical exercise — it's a foundation for quality, reliable, and ethical public health research. By choosing the right method and inputs, you're not just doing statistics; you're building trust in your results and ensuring better decisions for health programs and policies.

🚀 Launch StudySizer