Course contentsShow
← Data Science
Lesson 372 of 2,14510. Hypothesis Tests for MeansFree lesson

Paired t-Test Statistic and Degrees of Freedom

Calculate the t-statistic using the mean and standard error of differences with n-1 degrees of freedom.

Paired t-Test Statistic and Degrees of Freedom

You'll learn how to calculate the t-statistic for paired data and determine its degrees of freedom.

Now that you've calculated the paired differences, it's time to test whether their average is significantly different from zero. The paired t-test statistic measures how many standard errors the mean difference is away from zero—just like the one-sample t-test you've already learned, but applied to your differences.

The Formula

The paired t-test statistic is calculated as:

t = (mean of differences - 0) / (standard error of differences)

Or more formally:

t = d̄ / (s_d / √n)

Where:

  • d̄ is the mean of your paired differences
  • s_d is the standard deviation of the differences
  • n is the number of pairs
  • The denominator is the standard error of the differences

Degrees of Freedom

For a paired t-test, the degrees of freedom equals:

df = n - 1

Where n is the number of pairs (not the total number of observations). You lose one degree of freedom because you're estimating the mean from your sample of differences.

Think of It This Way

Imagine you're testing whether a training program improves test scores. You have 20 people who took tests before and after. You calculate 20 difference scores. Your paired t-test treats these 20 differences as a single sample, so you have df = 20 - 1 = 19 degrees of freedom. The t-statistic tells you how unusually large (or small) your average improvement is compared to random chance.

Key Takeaway: The paired t-test statistic divides the mean difference by its standard error, and uses n - 1 degrees of freedom where n is the number of pairs—treating differences as a one-sample problem.