In these slides, I will explain what a p-value is and how it is found. First, I will talk about null and alternative hypotheses, which are related concepts.
2026-05-31
In these slides, I will explain what a p-value is and how it is found. First, I will talk about null and alternative hypotheses, which are related concepts.
A null hypothesis is the statement that there is no relationship between variables. An alternative hypothesis is that A does cause B.
The null hypothesis is written as:
\[ H_0: \mu = 75 \]
The dashed line is the alternative hypothesis, and the solid line is the null hypothesis. The null hypothesis assumes the population mean is 75. The alternative hypothesis assumes the true mean is greater than 75. The p-value is the probability of observing a result at least as extreme as the one obtained, assuming the null hypothesis is true. If the p-value is very small, the observed result is unlikely to have come from the null distribution alone, providing evidence in favor of the alternative hypothesis.
Here’s a little more on the p-value.
The p-value is often written as
\[ p = P(\text{data} \mid H_0) \]
P-value stands for probability value.
The p value represents the probability that the data support the null hypothesis. Big p-values support the null hypothesis, and small ones don’t support the null hypothesis. In statistics terms, large p values fail to reject the null hypothesis and small p values allow us to reject the null hypothesis in support of the alternative hypothesis.
This is the normal distribution curve.
Imagine you’re flipping a coin 100 times. Your null hypothesis would be that the coin is fair, meaning you’d have 50 flips turn up heads and 50 tails. If you graphed all the possible outcomes, you would get something like a bell curve. That’s the normal distribution you see pictured above. The center is 50 heads because that’s what we’d expect from a fair coin.
The p-value asks, “How far is this from the center?”
Suppose we flip a coin 100 times and it gives us 70 heads.
The null hypothesis, again, is that the the coin is fair; however, we observed 70 heads. The red line represents outcomes of 70 heads or more. The p-value is the probability of getting 70 heads or something even more extreme if the coin is truly fair.
Suppose we flip a coin 100 times and it gives us 48 heads.
This time, we observed 48 heads, which is very close to the expected value of 50 heads. The red shaded area represents outcomes of 48 heads or fewer. Because 48 heads is not far from the center of the distribution, the shaded area is relatively large. This results in a large p-value, meaning that observing 48 heads is not unusual if the coin is truly fair. Therefore, we would not reject the null hypothesis.
So why do we need p-values?
If we repeat an experiment or collect a different sample, we will rarely get exactly the same results. A p-value helps us determine whether an observed difference is large enough that it is unlikely to have occurred by random chance alone. In other words, it helps us distinguish between ordinary variation in the data and evidence that a real effect may exist. The smaller the p-value, the stronger the evidence against the null hypothesis.
Thank you for reading!