Intermediate

双样本 t 检验计算器

使用双样本 t 检验,检验两个独立样本的均值是否存在显著差异。
Sample mean x̄₁
Sample standard deviation s₁
Sample size n₁
Sample mean x̄₂
Sample standard deviation s₂
Sample size n₂

Variance assumption

Alternative hypothesis

t statistic
1.4026

Fail to reject the null hypothesis at α = 0.05.

tt = (x̄₁ − x̄₂) / SE placed on the t-distribution (approximated as N(0,1))
Degrees of freedom
56.1733
p-value
0.1662
Mean difference
4
标准误差
2.8519
Decision
Not significant
Step by step
  1. 1

    Standard error (Welch)

    √(100÷30 + 144÷30) = 2.8519
    SE = √(s₁²/n₁ + s₂²/n₂) — no pooling under the Welch assumption.
  2. 2

    Mean difference

    52 − 48 = 4
  3. 3

    t statistic

    4 ÷ 2.8519 = 1.4026
结果仅为一般参考性的估算,并非专业建议——在依赖这些重要结果之前,请务必自行独立核实。 阅读完整免责声明.
快速解答

这个计算器是如何工作的?

输入每组的均值、标准差和样本量,运行独立双样本 t 检验。选择 Welch(不等方差)或合并(等方差)检验,以及单尾或双尾备择假设。工具将返回 t 统计量、自由度、p 值,以及在 α = 0.05 下的拒绝或不拒绝决策。

公式
Welch: t = (x̄₁ − x̄₂) / √(s₁²/n₁ + s₂²/n₂); 合并: t = (x̄₁ − x̄₂) / √(sp²(1/n₁ + 1/n₂))
How this is calculated

分别输入两个独立组的样本均值、标准差和样本量,然后选择是否假设方差相等,并选择单尾或双尾备择假设。该检验将均值之差与随机波动的预期水平进行比较,从而得出 t 统计量。

对于 Welch(不等方差)检验,标准误差为 √(s₁²/n₁ + s₂²/n₂),自由度采用 Welch–Satterthwaite 近似公式:df = (s₁²/n₁ + s₂²/n₂)² / [(s₁²/n₁)²/(n₁−1) + (s₂²/n₂)²/(n₂−1)]。对于合并检验,使用单一合并方差 sp² = ((n₁−1)s₁² + (n₂−1)s₂²)/(n₁+n₂−2),标准误差变为 √(sp²(1/n₁ + 1/n₂)),自由度为 df = n₁ + n₂ − 2。

p 值通过正则化不完全 Beta 函数计算 Student t 累积分布得出。双尾 p 值为 2·P(T > |t|);单尾 p 值使用单侧尾部。每组至少需要两个观测值,且标准差须为非负数。Welch 检验是更稳健的默认选择,因为它不假设两个总体具有相同的方差。

常见问题

当两组方差可能不同或样本量不等时,应使用 Welch 检验——它更稳健,是推荐的默认选项。只有在确信总体方差相等时,才使用合并检验。

它表示在两个总体均值真正相等的情况下,观测到至少这么大均值差异的概率。p 值低于显著性水平(通常为 0.05)则拒绝均值相等的零假设。

不同。此检验适用于两个独立(非配对)组。配对 t 检验适用于同一受试者被重复测量两次,或观测值具有自然配对关系的情况。

也称为

双样本t检验
独立样本t检验
welch t检验
均值比较
两样本t检验
非配对t检验
two sample t test

APA

TG we-Calculate Editorial Team. (2026). 双样本 t 检验计算器 [Online calculator]. TG we-Calculate. https://we-calculate.com/zh/calculator/two-sample-t-test-calculator

Chicago

TG we-Calculate Editorial Team. "双样本 t 检验计算器." TG we-Calculate. 2026. https://we-calculate.com/zh/calculator/two-sample-t-test-calculator.

IEEE

TG we-Calculate Editorial Team, "双样本 t 检验计算器," TG we-Calculate, 2026. [Online]. Available: https://we-calculate.com/zh/calculator/two-sample-t-test-calculator

BibTeX

@misc{wecalculate_two_sample_t_test_calculator, title = {双样本 t 检验计算器}, author = {{TG we-Calculate Editorial Team}}, howpublished = {\url{https://we-calculate.com/zh/calculator/two-sample-t-test-calculator}}, year = {2026}, note = {TG we-Calculate} }

这个计算器对您有帮助吗?