How to calculate sample size with pilot study

I'll help you understand how to calculate sample size using pilot study data. Let me search for current guidance on this important topic.
Searching PubMed

pilot study sample size calculation

Searching the Web

how to calculate sample size from pilot study data

Let me get the full details from the most relevant recent papers on pilot study sample size calculation.
Reading Article

PMID: 40780848

Reading Article

PMID: 38331310

Reading Article

PMID: 35167592

Based on current research, here's how to calculate sample size using pilot study data:

Key Principle

Pilot studies typically do not require formal power calculations. Instead, sample size should be justified based on the pilot study's specific goals. The Kunselman review (2024) clarifies that while power calculations are standard for definitive trials, pilot studies serve different purposes—feasibility, parameter estimation, and proof-of-concept—so justification differs.

Main Approaches

1. Using Pilot Data to Estimate Effect Size for the Main Trial

This is the most common use. Steps:
  • Collect pilot data from a small sample (typically 20-50 participants, depending on your research question)
  • Calculate the effect size from your pilot results using:
    • Standard deviation (SD) for continuous outcomes
    • Response rate or proportion for binary outcomes
    • Standardized effect size (Cohen's d, odds ratio, etc.)
  • Plug into standard power calculation using the pilot's estimated parameters
Example (continuous outcome): If your pilot study (n=30) measures blood pressure reduction and finds SD = 12 mmHg, use this SD in your main trial's power calculation instead of guessing.

2. Accounting for Uncertainty from Pilot Variance

O'Neill (2022) describes a method that accounts for uncertainty in the population variance parameter when using pilot data. This approach inflates the sample size slightly to protect against underestimation of variance (which is common in small pilots):
  • Calculate variance estimate from pilot data
  • Apply an adjustment factor that reflects confidence in that estimate
  • This prevents underpowering the main trial if pilot variance was unexpectedly low

3. For Pilot Study Sample Size Itself

Justify pilot sample size based on:
  • Precision of parameter estimation: Aim for 95% CI width narrow enough to be useful. Rule of thumb: 12-30 participants often sufficient for estimating a single mean or proportion.
  • Feasibility/recruitment goals: "We will recruit 25 participants to assess recruitment rate and protocol acceptability"
  • Number needed to observe rare events: If testing adverse events, size for observing 3-5 events

Practical Formula When Pilot Estimates Variance

For the main trial, after collecting pilot data:
n = (Z² × s² / d²) × inflation factor
Where:
  • Z = critical value (1.96 for 95% confidence)
  • s² = variance from pilot study
  • d = desired precision (e.g., margin of error)
  • Inflation factor = typically 1.1-1.3, accounts for pilot uncertainty

Common Mistakes to Avoid

  1. Don't use pilot sample size as your main trial size - this nearly guarantees underpowering
  2. Don't assume pilot estimates are exact - always inflate slightly for uncertainty
  3. Don't skip the pilot - it's far better to estimate variance empirically than guess
  4. Add 10-20% for attrition after your calculated n, regardless of method

Documentation Template

"The main trial sample size (n=XXX) was calculated using pilot study data (n=YYY). The pilot study estimated [outcome variance/effect size]. Using standard power calculation with 80% power and 0.05 alpha, accounting for 15% attrition, the required sample size is XXX."
The 2025 BMJ tutorial by Ying et al. provides an in-depth walkthrough of pilot-to-main-trial sample size planning if you need more detailed guidance.
Would you like help with a specific calculation, or do you have pilot data you'd like to work through?

We have sample size is 200 say p value, z and n values how to calculate with formulas

Searching the Web

sample size formula proportion Z p q n 95% confidence

For a prevalence/proportion study, use:
[ n=\frac{Z^2 \times p \times q}{d^2} ]
Where:
  • n = required sample size
  • Z = Z value for confidence level
    • 95% confidence: (Z=1.96)
    • 90% confidence: (Z=1.645)
    • 99% confidence: (Z=2.576)
  • p = expected prevalence/proportion from your pilot study, in decimal form
  • q = (1-p)
  • d = allowable error/precision, in decimal form
This standard proportion formula is also described in this sample-size overview.

Important: p is not the p-value

In this formula, p means prevalence/proportion, not the statistical p-value from a hypothesis test.
For example, if 40 of 200 pilot participants have the outcome:
[ p=\frac{40}{200}=0.20 ]
[ q=1-0.20=0.80 ]
Assume:
  • 95% confidence: (Z=1.96)
  • precision (d=0.05), meaning ±5%
Then:
[ n=\frac{(1.96)^2(0.20)(0.80)}{(0.05)^2} ]
[ n=\frac{3.8416 \times 0.16}{0.0025} ]
[ n=245.86 ]
Round up:
[ \boxed{n=246} ]
If you expect 10% non-response/dropout:
[ n_{\text{final}}=\frac{246}{1-0.10}=273.3 ]
[ \boxed{\text{Recruit 274 participants}} ]

If your pilot sample is 200

Use the pilot to calculate (p):
[ p=\frac{\text{number with outcome}}{200} ]
Examples:
Pilot resultpqRequired n at 95% CI, d = 5%
20/200 have outcome0.100.90138
40/200 have outcome0.200.80246
100/200 have outcome0.500.50385
160/200 have outcome0.800.20246
The largest sample is needed when (p=0.50), because uncertainty is greatest.

If total population is only 200

If there are only 200 people in the whole population, first calculate (n_0) with the above formula, then apply the finite population correction:
[ n=\frac{n_0}{1+\frac{n_0-1}{N}} ]
Where:
  • (n_0) = initial calculated sample size
  • (N=200) = total population
For example, if (p=0.50), (d=0.05), then (n_0=384.16):
[ n=\frac{384.16}{1+\frac{384.16-1}{200}} ]
[ n=131.6 ]
[ \boxed{n=132} ]
Give me:
  1. number with outcome in your pilot sample of 200,
  2. desired precision, such as 5% or 10%, and
  3. whether 200 is the pilot sample or the total population,
and I can calculate the exact final sample size.
This is a shared conversation. Sign in to Orris to start your own chat.