T-Statistic Calculator
How it Works
01Enter Sample Parameters
Provide sample mean, population mean, sample standard deviation, and sample size.
02Compute Standard Error
Standard error = s/√n — the expected variability of the sample mean.
03Calculate T-Statistic
t = (x̄ − μ) / SE — measures deviation in standard error units.
04Get Degrees of Freedom
df = n−1 determines the t-distribution shape for p-value lookup.
Introduction
The t-distribution was developed by statistician William Sealy Gosset in 1908 under the pseudonym "Student," which is why t-tests are also called Student's t-tests. The t-distribution is similar to the normal distribution but has heavier tails, which accounts for the additional uncertainty when working with small samples and unknown population standard deviations.
This calculator computes the t-statistic for a one-sample t-test: comparing a sample mean to a known or hypothesized population mean. You enter the sample mean, population mean (null hypothesis value), sample standard deviation, and sample size, and the calculator returns the t-statistic and degrees of freedom needed to look up the p-value in a t-distribution table.
The t-statistic is used to determine statistical significance — whether the difference between your sample and the hypothesized value is likely due to chance or represents a real effect. A larger absolute t-value indicates a bigger difference relative to variability, making it less likely to occur by chance.
Common applications include clinical trials (comparing treatment and control groups), A/B testing in marketing, quality control testing, and any situation where you need to determine if a sample mean differs significantly from a benchmark value.
The formula
t = (x̄ − μ₀) / (s / √n)
Where:
Degrees of Freedom:
df = n − 1
Standard Error:
SE = s / √n
The standard error measures how much the sample mean is expected to vary from sample to sample.
Calculation In Practice
A factory claims its bolts have a mean diameter of 10mm. A quality inspector measures 25 bolts and finds:
Step 1: Standard Error = 1.2 / √25 = 1.2 / 5 = 0.24
Step 2: t = (10.4 − 10) / 0.24 = 0.4 / 0.24 = 1.667
Step 3: df = 25 − 1 = 24
With df=24 and t=1.667, p ≈ 0.109 (two-tailed). Not significant at α=0.05.
Typical Use Cases
Clinical Trials
Quality Control
A/B Testing
Educational Research
Financial Analysis
Technical Reference
Critical Values (two-tailed, α=0.05):
Effect Size (Cohen's d):
d = (x̄ − μ₀) / s
Assumptions:
Key Takeaways
Always pair the t-statistic with degrees of freedom to find the correct p-value. For two-sided tests, compare the absolute t-value to the critical t-value at your chosen significance level (α). For samples larger than 30, the t-distribution approaches the standard normal distribution, making z-tests and t-tests yield nearly identical results.
Remember that statistical significance does not imply practical significance — always consider effect size (Cohen's d) alongside the t-statistic for a complete interpretation of your results.