brand banner

p-value and hypothesis testing

Simple facts about p-value and hypothesis testing

Updated Β· 1 min read Β· #statistics

p-value and hypothesis testing

Simple facts about p-value and hypothesis testing

Question

Suppose we test 20 independent hypotheses, with no real effect in any of the cases. For each test, we require 𝑝<0.05 to claim a significant result.

What is the expected number of false positives when performing all 20 tests?

Notes

  • no β€œreal” effect means in reality, the null hypothesis was true for every test
  • interpretation: null hypothesis is always true in this example
  • 𝑝=0.05 means there’s a 5% chance we get a result with enough error to be at least this far away from the null hypothesis

Since null hypothesis (𝐻0) is true in this case, for every test, there’s only a 5% chance to get a result that comes with 𝑝 value 𝑝<0.05. There are 20 independent trials, so 5% of 20 is 1 (on average).

Question

What is the probability of obtaining at least one satistically significant result when performing all 20 tests, even though none of the effects are real?

Notes

  • This follows the binomial distribution
  • Instead of dealing with 𝑃(𝑋=1)+𝑃(𝑋=2)+β‹―+𝑃(𝑋=20), we use the complement

Let 𝑋 be the number of statistically significant results (false positives) in the 20 tests.

𝑃(𝑋β‰₯1)=1βˆ’π‘ƒ(𝑋=0)=1βˆ’(200)𝛼0(1βˆ’π›Ό)20=1βˆ’0.9520β‰ˆ0.64


Β© 2026 James Yap

Personal Website and Knowledge Base