Sample size calculation
Plan sample size or statistical power for a specified study design and effect size.
Data requirements
No participant dataset is required. Enter planning assumptions directly for a two-group comparison.
Parameters
Names match the analysis form. Starting values describe a newly loaded form; column selections depend on your uploaded data. Matching example column names may be preselected. Review every selection before running.
“Optional / conditional” fields may be required by a particular mode or method. The explanation states when each field takes effect. Hold Ctrl / Command to select multiple columns.
Study
Choicemeans compares continuous means; proportions compares event probabilities.
- means
-
means - proportions
-
proportions
Design
Choicedifference, superiority, non-inferiority and equivalence select the planning formula. The margin and effect direction must match the design.
- difference
-
difference - superiority
-
superiority - non inferiority
-
non-inferiority - equivalence
-
equivalence
Ratio
NumberPositive group allocation ratio passed to the planning formula, up to 20. A value of 1 plans equal allocation; review both reported group sizes when changing it.
Alpha
NumberType I error probability strictly between 0 and 0.5. Enter 0.05 for 5%, rather than 5.
Power
NumberTarget power strictly between 0.5 and 1. Enter 0.8 for 80%.
Sd
NumberPositive common standard deviation, shown and validated for means only.
Theta
NumberPlanned treatment-minus-control mean effect for means. The proportions effect instead uses p1 minus p2.
Delta
NumberSigned margin for superiority/non-inferiority, or positive equivalence margin. The planned effect must exceed the signed margin for superiority/non-inferiority. Equivalence requires delta > absolute planned effect. Ignored for difference.
P1
NumberFirst event probability for proportions, strictly between 0 and 1. Hidden and ignored for means. The proportions effect is p1 minus p2.
P2
NumberSecond event probability for proportions, strictly between 0 and 1. Together with p1, supplies the planned proportions effect.
Example settings
Open the analysis and enter these assumptions. No data upload is needed.
Results
The sample-size table contains the planning formula's group sizes and rounded-up sizes. Review assumptions and the reported allocation before using the plan. Additional downloadable analysis-summary and diagnostics tables describe the analysis scope and method checks. Selected-variable missingness is reported where applicable. Diagnostics do not establish external validity or verify untested assumptions.
Review the reported method, observation count and notes alongside the estimates. Result tables can be downloaded as CSV and the figure as PNG.
Notes & limitations
- A difference design requires a nonzero planned effect. The bundled example uses means, effect 0.5, SD 1, alpha 0.05 and power 0.8.
- This interface calculates sample size for a specified power; a separate achieved-power mode is not available.