t-tests introduction
参考资料:
- Wikipedia: Student’s t-test
- statwing: T-Test (Independent Samples)
- lærd: Independent T-Test for Two Samples
- lærd: Dependent T-Test for Paired Samples (cont…)
0. TypesPermalink
A t-test is a statistical hypothesis test in which the test statistic follows a Student’s t distribution if the null hypothesis is supported. 实际应用却有 4 大类:
- One-sample t-test
- Slope of a regression line
- Independent two-sample t-test
- Dependent t-test for paired samples
我们这里一不讲 assumption,二不深入计算方法,只介绍 hypotheses,知道这几种 t-tests 测的是什么内容就足够了。
1. One-sample t-testPermalink
Giving a sample, we test
: the underlying population mean is equal to a specified value : the underlying population mean is not equal to a specified value
We use the statistic
where
Although the parent population does not need to be normally distributed, the distribution of the population of sample means,
2. Slope of a regression linePermalink
Suppose one is fitting the model
where
We want to test
: the slope is equal to some specified value : the slope is not equal to some specified value
3. Independent two-sample t-testPermalink
: (The population means from the two unrelated (i.e. independent) groups are equal.) : (The population means from the two unrelated (i.e. independent) groups are not equal.)
计算方法根据以下指标有所不同:
- Equal sample sizes, equal variance
- Equal or unequal sample sizes, equal variance
- Equal or unequal sample sizes, unequal variances (Welch’s t-test)
4. Dependent t-test for paired samplesPermalink
This test is used when the samples are dependent; that is,
- when there is only one sample that has been tested twice (repeated measures) or
- when there are two samples that have been matched or “paired” (比如犯罪率调查,一张大表里有 “青年犯罪人数” 和 “中年犯罪人数”,它们不是独立的,所以可以看做是两个 sample,我们可以用 dependent t-test 调查 “那个年龄段平均犯罪率更高” 这样的问题).
: (The population means from the two related (i.e. dependent) groups are equal.) : (The population means from the two related (i.e. dependent) groups are not equal.)
Comments