0

我有两个数据集。

每个数据集都有很多相同物种的列,在两个不同的场合采样。

现在我想看看物种的平均值是否彼此显着不同。我了解到我必须为此进行配对 t 检验。

我想出这样做的公式是:

 t.test(dataset1$'specie',dataset2$'specie')

Q1:我是否使用正确的函数进行配对 t 检验?

Q2:鉴于我实际上做得正确。我如何解释答案?. t= 告诉我什么?p 值低,这是否意味着物种的平均值相似或不相似?

Q3:有没有办法让 R 自动比较两个数据集中的所有相同物种,还是我必须手动进行?

4

1 回答 1

0
  1. t.test(dataset1$'specie', dataset2$'specie', paired=TRUE)
    Without it, it is the Welch's t test which does not sound like what you are looking for.

  2. Simply put, high T mean that it is highly unlikely the two population means are similar.
    Low p values mean that they are not similar. It depends on your cutoff point but 1.096e-10 is incredibly low. If you were looking for a cutoff at 0.05, then anything above that is considered not significant.

    See the following link for more details:
    https://www.r-bloggers.com/paired-students-t-test/

  3. You can make it a function or object or something.

于 2017-02-07T19:48:56.980 回答