Power Analysis Calculator
Calculate required sample size, statistical power, or minimum detectable effect size for your research study design.
Power Analysis Calculator
Calculator
Adjust values & calculateEnter your values below. Every result is computed in your browser โ no data is sent to any server.
Formula: n = ((Z_alpha + Z_beta) / d)^2
Worked example โ Required: 32 per group | 64 total participants | Effect: Medium (d=0.5)
Formula
n = ((Z_alpha + Z_beta) / d)^2
Where n is the required sample size per group, Z_alpha is the critical value for the significance level (1.96 for two-tailed alpha=0.05), Z_beta is the critical value for the desired power (0.842 for 80% power), and d is Cohen's d effect size. This formula can be rearranged to solve for power or minimum detectable effect size.
Worked Examples
Example 1: Clinical Trial Sample Size
Problem:Determine sample size for a two-group comparison with medium effect size (d=0.5), alpha=0.05 two-tailed, 80% power.
Solution:Z_alpha/2 = Z_0.025 = 1.96 (two-tailed) Z_beta = Z_0.80 = 0.842 n per group = ((1.96 + 0.842) / 0.5)^2 = (2.802 / 0.5)^2 = (5.604)^2 = 31.4, round up to 32 Total N = 32 x 2 = 64 participants
Result:Required: 32 per group | 64 total participants | Effect: Medium (d=0.5)
Example 2: Minimum Detectable Effect
Problem:With 100 participants per group, alpha=0.05 two-tailed, and 80% power, what is the smallest detectable effect?
Solution:Z_alpha/2 = 1.96 Z_beta = 0.842 MDE = (Z_alpha + Z_beta) / sqrt(n) = (1.96 + 0.842) / sqrt(100) = 2.802 / 10 = 0.2802 This is a small-to-medium effect size per Cohen guidelines.
Result:Minimum Detectable Effect: d = 0.28 (Small-Medium) | n = 100 per group
Frequently Asked Questions
What is statistical power analysis and why is it important?
Statistical power analysis is the process of determining the sample size needed to detect an effect of a given size with a certain degree of confidence. Power is the probability that a statistical test will correctly reject the null hypothesis when it is actually false, in other words, the probability of detecting a real effect. A power of 0.80 means there is an 80 percent chance of finding a significant result when a true effect exists. Power analysis is critical because underpowered studies waste resources by having too few participants to detect real effects, leading to false negatives and inconclusive results. Overpowered studies waste resources by enrolling more participants than necessary. Regulatory bodies and journal reviewers increasingly require a priori power analysis as part of study design to ensure research is adequately sized and ethically justified.
What is effect size and how do I choose the right one for my study?
Effect size quantifies the magnitude of the difference or relationship you expect to find. Cohen's d is the most common measure for comparing two group means, defined as the difference between means divided by the pooled standard deviation. Cohen provided general benchmarks: 0.2 is small, 0.5 is medium, and 0.8 is large. However, these benchmarks should be used cautiously because what constitutes a meaningful effect varies by field. In clinical research, a small effect size might be highly important if it represents lives saved. In educational psychology, medium effects are typical for interventions. The best approach is to base your expected effect size on prior research, pilot study data, or the minimum effect that would be practically meaningful. Using overly optimistic effect size estimates leads to underpowered studies, so it is better to err on the conservative side.
What is the relationship between alpha, beta, power, and sample size?
These four parameters are mathematically interconnected such that knowing any three determines the fourth. Alpha is the probability of a Type I error, falsely rejecting a true null hypothesis, typically set at 0.05. Beta is the probability of a Type II error, failing to reject a false null hypothesis. Power equals 1 minus beta and represents the probability of correctly detecting a true effect. Sample size is the number of observations needed. Decreasing alpha, meaning being more strict about false positives, requires a larger sample size to maintain the same power. Increasing desired power also requires more participants. Smaller expected effect sizes need dramatically larger samples because subtle differences require more data to distinguish from noise. The practical implication is that researchers must balance these parameters against budget constraints and ethical considerations regarding participant burden.
What is the difference between a one-tailed and two-tailed test in power analysis?
A one-tailed test examines whether an effect exists in a specific direction, for example testing whether a new drug performs better than a placebo but not whether it performs worse. A two-tailed test checks for effects in either direction. One-tailed tests require smaller sample sizes for the same power because all of the alpha is concentrated in one tail of the distribution, making it easier to reach significance. However, two-tailed tests are generally preferred and often required by journals because they are more conservative and do not assume the direction of the effect in advance. Using a one-tailed test when a two-tailed test is appropriate inflates the Type I error rate for effects in the untested direction. Most power analyses should use two-tailed tests unless there is strong theoretical justification for a directional hypothesis.
How do I interpret power analysis results and what sample size should I target?
The conventional minimum power level is 0.80, meaning an 80 percent probability of detecting a real effect, though many researchers now recommend 0.90 or higher for critical studies. When interpreting results, consider feasibility constraints alongside statistical requirements. If the calculated sample size is impractical, you have several options: accept a larger minimum detectable effect size, use a less stringent alpha level, switch to a more powerful statistical test, or reduce measurement error through better instruments. Always report your power analysis assumptions including effect size, alpha, and desired power. For clinical trials, regulatory agencies often require 90 percent power. For exploratory research, 80 percent may suffice. Remember that the calculated sample size is per group for between-subjects designs, so multiply by the number of groups for the total sample needed. Account for expected attrition by inflating your target by 10 to 20 percent.
Why does halving the expected effect size quadruple the required sample size?
In n = ((Z_alpha + Z_beta) / d)^2 the effect size sits in the denominator and the whole ratio is squared, so required n scales with 1 / d^2. At alpha 0.05 two-tailed and 80 percent power, d = 0.5 needs about 32 per group; d = 0.25 needs about 126, four times as many. This quadratic penalty is why optimistic effect size guesses are the single most common cause of underpowered studies, and why small-effect research demands sample sizes that are often infeasible.
Why is Z_beta taken from one tail while Z_alpha is split across two?
Alpha is divided between both tails in a two-sided test, so the critical value is Z at 1 - alpha/2, which is 1.96 for alpha = 0.05. Power, by contrast, is the probability of landing in the rejection region on the side where the true effect actually lies, which is inherently one-directional; the contribution from the far tail is negligible. So Z_beta for 80 percent power is Z at 0.80, or 0.842, and for 90 percent power it is 1.282, not the two-tailed equivalents.
What is post hoc observed power and why is it criticised?
Observed power is calculated after the fact by substituting the effect size actually measured into a power formula. It adds no information, because it is a deterministic function of the p-value: a non-significant result always yields low observed power, and a significant one always yields high power. Using it to argue that a null result was merely underpowered is therefore circular. The informative post hoc alternative is to report the confidence interval around the observed effect, which shows directly which magnitudes the study could rule out.
How does an unequal allocation ratio change the sample size requirement?
Equal group sizes are the most efficient allocation for a fixed total sample. Moving to a ratio of k to 1 multiplies the total needed by (1 + k)^2 / (4k), so a 2:1 randomisation costs about 12.5 percent more participants overall for the same power, and 3:1 costs about 33 percent more. Unequal allocation is still worth it when one arm is far cheaper or when investigators want more safety exposure data on the treatment arm, but the trade-off should be priced in deliberately.
How do I adjust the sample size for a cluster randomised design?
When randomisation happens at the level of clinics, classrooms or stores, observations inside a cluster are correlated and carry less independent information. Multiply the individually randomised sample size by the design effect, 1 + (m - 1) x ICC, where m is the average cluster size and ICC is the intracluster correlation coefficient. Even a small ICC inflates the requirement sharply when clusters are large, because m - 1 multiplies it. Ignoring the design effect produces a study that is badly underpowered despite looking adequate on paper.
References
Reviewed for accuracy by Daniel Agrici, Founder & Lead Developer ยท Editorial policy
Related Calculators
๐งฎDescriptive Statistics Calculator
Calculate descriptive statistics with inputs, formulas, and instant results.
๐งฎBayesian Posterior Calculator
Calculate bayesian posterior with inputs, formulas, and instant results.
๐งฎFalse Discovery Rate Calculator
Calculate false discovery rate with inputs, formulas, and instant results.
๐งฎCorrelation Coefficient Calculator
Calculate correlation coefficient with inputs, formulas, and instant results.
๐งฎBinomial Distribution Calculator
Calculate binomial distribution with inputs, formulas, and instant results.
๐งฎChi Square Test Calculator
Calculate chi square test with inputs, formulas, and instant results.
๐งฎZtest Proportions Calculator
Calculate ztest proportions with inputs, formulas, and instant results.