Paired t-test: testing a mean change
A paired t-test asks whether the population mean of within-pair differences is zero.
Fit
When to use it, and when not to
Use it when
- Each person has two continuous measurements, or each observation has a prespecified matched partner.
- You want the average difference, using one difference per complete pair.
Not when
- The groups contain different, unmatched people. Use an independent t-test, covered in the tests-for-means overview. Read: Choosing a test for means
- There are several visits or patients share clinics. Use a mixed-effects model. Read: Mixed-effects models
- A small sample has strongly skewed differences. Consider a prespecified rank-based analysis if its target fits. Read: Mann-Whitney U test
Before you start
What you need
- The pair identifier and subtraction orderKeep each pair together. State whether the difference is after minus before or the reverse.
- The complete-pair count, mean difference and standard deviation of differencesThe standard deviations at each visit cannot replace the spread of within-pair changes.
- Which pairs lack a measurementExplain why data are missing and how this may change the population being described.
- Differences from separate pairs are independent.How to check: Check for family, clinic or other shared sources of dependence.
- Differences are roughly normal for small-sample t inference.How to check: Plot the differences. Do not require each raw measurement to have a normal distribution.
- The measured difference represents the intended change.How to check: Check units, timing, and floor or ceiling effects before treating the scale as continuous.
Plain language
How it works
Subtract the first value from the second for each pair. The paired t-test is a one-sample t-test on those differences. Divide their mean by their standard error. The degrees of freedom equal the number of complete pairs minus one.
Wang and Li’s simulations show that ceiling or floor effects can distort paired inference. Guo and colleagues study partially paired data. A complete-pair analysis can lose information; using unpaired observations needs an appropriate model.
Worked example
A worked example
- Setting
- A clinic records blood pressure before and after a care change in 25 complete pairs.
- Question
- What is the mean within-person change?
- Approach
- Pairs: n = 25, mean difference = -4.6, SD of differences = 7.9. Differences are after minus before.
- Result
- The mean change is -4.60 mmHg; t = -2.91, df = 24, p = 0.008. The calculator’s approximate interval is -7.70 to -1.50 mmHg.
- What it means
- The interval uses 1.96 standard errors; final paired t inference uses a t critical value. Without a concurrent control, the change does not establish causation.
In practice
Recent studies PubMed search · not vetted
Watch out
Common mistakes
The one to remember
The normality assumption concerns within-pair differences, not the two raw measurements. A before-after change alone does not establish a treatment effect.
- Entering the standard deviation from the final visit.Instead: Compute each person’s difference, then take the standard deviation of those differences.
- Dropping incomplete pairs without discussing selection.Instead: Describe the missing-data assumption and assess how losses could change the result.
Inside Mallard
How Mallard uses this
Mallard links this article to its paired t-test calculator. Its displayed interval uses a normal approximation. The method registry links this method to its published analysis article and code.
paired-t-test).analysis.paired_t_test, the id a plan cue records.Work it out
Related Learn pages
Related designs and methods
Evidence
Sources & further reading
- Tobit modeling for dependent-sample t-tests and moderated regression with ceiling or floor data (opens in a new tab) · Behav Res Methods · doi 10.3758/s13428-025-02904-y
- Optimal weighted two-sample t-test with partially paired data in a unified framework (opens in a new tab) · J Appl Stat · doi 10.1080/02664763.2020.1753027