Power in this visualization
The power of a test is the probability that it rejects the null hypothesis when a particular alternative is true. Here says that a machine fills bags with g on average; bag weights are independent and normal with g, and a study weighs bags and rejects at level when their mean falls past a cut-off. The power at a true mean is the area of the true curve beyond that cut-off; the rest, , is the chance of missing the difference, a type II error. At there is nothing to miss, and the power is itself.
What does power depend on? For the test of with a shortfall , the power is . A larger gap or more bags raise it; a stricter moves the cut-off away from 500 and lowers it. Because enters only through , the number of bags needed for a given power grows like . The direction matters as much: if the machine actually overfills, the power of the test of falls toward 0, and more bags only push it lower. A two-sided test splits between the tails, so it catches a gap on either side, but on the side a one-sided test watches, it has less power than that test.
Why does a non-significant result not show that there is no difference? Because a test with low power usually misses a real one: with 25 bags at , the one-sided test catches a machine 2 g short only about a quarter of the time, so most studies of it end non-significant. What a non-significant result is worth depends on the power against a difference worth finding, and that is worked out before the data are seen: choose the smallest gap that matters, then an that gives enough power, often 80%.
Why do significant estimates exaggerate the difference on average when power is low? Take a machine that really underfills, tested for underfilling. Only studies whose mean happens to fall far below 500 pass the cut-off, so the significant ones are a selected group: their average estimate is the mean of the true curve beyond the cut-off, a larger shortfall than the true one. The cut-off itself sets a floor: with 25 bags at , a significant result must estimate a shortfall of more than about 3.29 g, whatever the true shortfall is. With and fixed, the smaller the true shortfall, the lower the power and the larger the factor by which significant estimates overstate it on average, a type M (magnitude) error; in a two-sided test some significant results even point the wrong way, a type S (sign) error. A body of research that reports only significant results carries this bias.
Things to notice
- Both curves in the upper layer are drawn to the same height for every . Read each shaded area as a share of its own curve; the narrowing, not the height, shows the spread shrinking.
- The power is not the probability that the machine is short. It is computed as if the true mean were the set on the page: .
Controls
- Drag the blue curve or its handle to move the true mean, or press the lower layer to send it there; drag a cut-off’s square handle to set .
- The 80% power row sets to the first sample size whose power reaches 80% at the current mean, and direction.
Related
Further reading: Wikipedia: Power (statistics); Andrew Gelman and John Carlin, “Beyond Power Calculations: Assessing Type S (Sign) and Type M (Magnitude) Errors”, Perspectives on Psychological Science (2014); John M. Hoenig and Dennis M. Heisey, “The Abuse of Power: The Pervasive Fallacy of Power Calculations for Data Analysis”, The American Statistician (2001).