One-Sample Test Statistic
t = (x̄ - μ₀) / (s/√n)Difference from hypothesized mean divided by standard error
Calculate one-sample, two-sample (independent), and paired t-test statistics with p-values and confidence intervals.
https://www.solvezi.com/statistics/t-test-calculator
Compare means • One-sample, Independent, & Paired t-tests
| # | Value | Action |
|---|---|---|
| 1 | ||
| 2 | ||
| 3 | ||
| 4 | ||
| 5 |
Degrees of Freedom
0
df
p-value
0.0000
Mean 1
0.0000
Mean 2
0.0000
Std Dev 1
0.0000
Std Dev 2
0.0000
Cohen's d (Effect Size)
0.0000
Very Small effect
95% Confidence Interval
[0.0000, 0.0000]
Interpretation:
Understanding T-Test
T-Test compares means between groups.
• One-sample: Sample mean vs hypothesized mean
• Independent: Two independent group means (Equal variance or Welch's)
• Paired: Two related measurements (before/after)
• p < 0.05 indicates statistically significant difference
T-Test Calculator • Compare means and test hypotheses
Master t-tests — understand one-sample, independent, and paired t-tests, interpret p-values and effect sizes, check assumptions, and apply to medical research, A/B testing, education, and quality control.
A t-test is a statistical test used to compare means between groups when the population standard deviation is unknown and sample sizes are small (typically n < 30).
"Is the observed difference between my sample mean(s) and the hypothesized value statistically significant, or could it be due to random sampling variation?"
t = (x̄ - μ₀) / (s/√n)Use case: Compare sample mean to known/hypothesized population mean
Example: Is the average height of students different from 170cm?
Hypothesis: H₀: μ = μ₀ versus H₁: μ ≠ μ₀
t = (x̄₁ - x̄₂) / √(s₁²/n₁ + s₂²/n₂)Use case: Compare means of two independent groups
Example: Compare test scores between treatment and control groups
Hypothesis: H₀: μ₁ = μ₂ versus H₁: μ₁ ≠ μ₂
t = d̄ / (sd/√n)Use case: Compare two related measurements (before/after)
Example: Measure blood pressure before and after treatment
Hypothesis: H₀: μ_difference = 0 versus H₁: μ_difference ≠ 0
t = (x̄ - μ₀) / (s/√n)Difference from hypothesized mean divided by standard error
t = (x̄₁ - x̄₂) / SE_{difference}Difference between group means divided by SE
t = d̄ / (s_d/√n)Mean difference divided by SE of differences
s_p² = [(n₁-1)s₁² + (n₂-1)s₂²] / (n₁+n₂-2)Weighted average of variances
CI = x̄ ± t_{crit} × SERange likely containing population mean difference
df = n - 1Based on sample size
df = n₁ + n₂ - 2Combined degrees
df = (s₁²/n₁ + s₂²/n₂)² / [ (s₁²/n₁)²/(n₁-1) + (s₂²/n₂)²/(n₂-1) ]Satterthwaite approximation
df = n - 1Based on number of pairs
d ≥ 0.8Groups differ by 0.8+ standard deviations
0.5 ≤ d < 0.8Groups differ by 0.5-0.8 SDs (noticeable difference)
0.2 ≤ d < 0.5Groups differ by 0.2-0.5 SDs (small but meaningful)
d < 0.2Negligible practical difference
Important:Statistical significance (p < 0.05) doesn't guarantee practical importance. Always report Cohen's d to interpret the magnitude of differences!
Check: Observations are independent within/between groups
Violation: Use mixed models or repeated measures ANOVA
Check: Data approximately normal (check Q-Q plots)
Violation: Use non-parametric tests (Mann-Whitney, Wilcoxon)
Check: Variances roughly equal across groups
Violation: Use Welch's t-test (more robust)
Robustness: T-test is reasonably robust to violations of normality, especially with larger samples (n ≥ 30). For severe non-normality, consider non-parametric alternatives like Mann-Whitney U or Wilcoxon signed-rank.
One-sample, independent, or paired based on study design
H₀: No difference, H₁: Difference exists
Typically α = 0.05 (5% Type I error risk)
Compute t-value using appropriate formula
Depends on test type and assumptions
Probability of observing this t-value if H₀ is true
Reject H₀ if p < α; otherwise fail to reject
Cohen's d = mean difference / pooled SD
Evaluate treatment effectiveness
Compare two versions of product/feature
Assess educational interventions
Test psychological interventions
Verify manufacturing improvements
Data-driven business decisions
Using t-test for non-independent data
Use paired t-test for related measurements, repeated measures ANOVA for >2 time points
Check study design before choosing test
Ignoring unequal variances
Use Welch's t-test (unequal variance) as safer default
Levene's test can check variance equality
Applying t-test to highly skewed data
Consider transformations or non-parametric alternatives
Large samples (n > 30) are robust to normality violations
Interpreting non-significance as 'no difference'
p > 0.05 means insufficient evidence, not proof of no difference
Report effect sizes and confidence intervals
Running multiple t-tests instead of ANOVA
Use ANOVA for 3+ groups to control Type I error
ANOVA followed by post-hoc tests if significant
Two-tailed (default) tests for any difference regardless of direction. One-tailed tests require a directional hypothesis (e.g., 'treatment increases scores') specified before data collection. One-tailed p-values are half of two-tailed, making significance easier but risking missed effects in opposite direction. Use two-tailed unless strong justification for one-tailed.
Student's t-test assumes equal variances between groups (homogeneity). Welch's t-test does not assume equal variances, making it more robust. Welch's test uses Satterthwaite approximation for degrees of freedom (often non-integer). Most statisticians recommend Welch's as default unless you have strong evidence variances are equal.
Larger samples increase statistical power (ability to detect true effects). With very small samples (n < 10), t-test may lack power to detect meaningful differences. With very large samples (n > 500), even trivial differences become statistically significant. Always report effect sizes alongside p-values.
Cohen's d measures effect size in standard deviation units: d = (mean difference) / (pooled standard deviation). Guidelines: d = 0.2 (small), 0.5 (medium), 0.8 (large). Unlike p-value, effect size indicates practical significance independent of sample size.
Z-test assumes known population variance and large sample sizes (n > 30). T-test uses sample variance (s instead of σ) with degrees of freedom, providing more accurate inference for small samples. As sample size increases, t-distribution approaches normal distribution.
Yes, with caution. For moderate sample sizes (n ≥ 30), t-test is robust to normality violations due to Central Limit Theorem. For small samples (n < 30), check normality with Q-Q plots or Shapiro-Wilk test. For severe violations, use non-parametric alternatives like Mann-Whitney U (independent) or Wilcoxon signed-rank (paired).
APA format: t(df) = value, p = p-value, d = effect size, 95% CI [lower, upper]. Example: 'An independent-samples t-test revealed a significant difference between groups, t(48) = 2.15, p = .037, d = 0.62, 95% CI [0.12, 1.12].' For non-significant results: 'No significant difference was found, t(48) = 0.85, p = .402.'
Minimum n = 2 per group technically, but extremely unreliable. Recommended minimum: n ≥ 10-15 per group for reasonable power. For small samples, consider: 1) Use Welch's t-test, 2) Check normality carefully, 3) Consider Bayesian t-test, 4) Report effect sizes with confidence intervals. For n < 5, interpretation is questionable.
1876-1937
Developed t-distribution (1908)
Worked for Guinness, published as 'Student'
1890-1962
Popularized t-test and significance testing
Also developed ANOVA and maximum likelihood
1923-1998
Developed effect size guidelines (1988)
Standardized d, small/medium/large benchmarks
Did You Know? William Gosset developed the t-test while working at Guinness Brewery to monitor beer quality with small samples. Guinness prohibited employees from publishing research, so Gosset published under the pseudonym 'Student' in 1908. The 'Student's t-test' remains one of the most widely used statistical tests today!
Significant Result:
"An independent-samples t-test revealed a significant difference between the control group (M = 22.4, SD = 3.2) and treatment group (M = 28.7, SD = 4.1), t(48) = 2.15, p = .037, d = 0.62, 95% CI [0.12, 1.12]."Non-Significant Result:
"No significant difference was found between the two groups, t(38) = 0.85, p = .402."Paired T-Test:
"A paired-samples t-test indicated that post-test scores (M = 85.2, SD = 8.3) were significantly higher than pre-test scores (M = 72.6, SD = 9.1), t(29) = 4.52, p < .001, d = 0.83, 95% CI [8.5, 16.7]."Required elements: Test type, degrees of freedom, t-statistic, p-value, effect size (Cohen's d), confidence interval, and group means/SDs for context.
T-test calculator and complete guide. Perform one-sample, independent, and paired t-tests. Calculate t-statistics, p-values, degrees of freedom, Cohen's d effect size, and confidence intervals. Learn assumptions, Welch's test, and reporting in APA format. Essential for medical research, A/B testing, education, psychology, and quality control.