2025-10-11

Understanding P-Value

How statistical decisions are helping decision makers to decide better

What is a P-value

  • A p-value is the probability of getting the data within the range of observed output, given that the null hypothesis Ho true
  • p = P(data as close or more close | Ho)
  • However, p < alpha, reject Ho

Hypothesis test

Given Ho: \[ H_0: \mu = 50 \quad \text{vs.} \quad H_A: \mu > 50 \] test statistic or 1-sample t-test is : \[ t = \frac{\bar{x} - \mu_0}{s / \sqrt{n}} \] This give us the p-value from the right-tail of the t-distribution

t-distribution example

Calculating P-value

Given observed statistic is t1, right-tailed p-value is: \[ p = P(T \ge t_1 \mid H_0) \] for 2 tailed: \[ p = 2 \times P(T \ge |t_1| \mid H_0) \]

## 
##  One Sample t-test
## 
## data:  sample
## t = 1.9161, df = 19, p-value = 0.03526
## alternative hypothesis: true mean is greater than 80
## 95 percent confidence interval:
##  80.30037      Inf
## sample estimates:
## mean of x 
##  83.07867

Right-tailed test demonstration

2-tailed test demonstration