为什么 scipy 和 Excel 为双样本 t 检验生成略微不同的 p 值?

Why scipy and Excel generate slightly different p-value for two-sample t-test?

对于python,默认为two-side test

from scipy import stats
import numpy as np
wt = np.array([71.93636,71.34689,72.2162])
mut = np.array([71.58995,70.82698,70.89562])
t, p = stats.ttest_ind(wt, mut, equal_var=False)
print(t,p)

我得到了

2.06163943002 0.108425721876

ExcelData 选项卡 - Data Analysis - t-Test: Two-Sample Assuming Unequal Variances 中,t 的值相同,但 [=20 的值略有不同=] (0.1084... 对比 0.1082...)

请问为什么?

如果你使用

from scipy import stats
stats.ttest_rel(wt,mut)

它应该与 Excel 中的相同计算匹配。

rel是相关样本,ind是独立样本。