成对 T 检验:complete.cases(x, y) 中的错误:并非所有参数的长度都相同?

Pairwise T-test: Error in complete.cases(x, y) : not all arguments have the same length?

我正在尝试 运行 成对 T 检验:

Dataundershootwithoutmeansminusstopdistance %>% 
  (Undershootextent ~ Condition, paired = TRUE, p.adjust.method = "bonferroni")

我得到这个结果:

Error in complete.cases(x, y) : not all arguments have the same length

但是,我不明白为什么会这样:

这是我的数据的一个子集:

Dataundershootwithoutmeansminusstopdistance
Targetdistance Condition ID Undershootextent
1 63.207  0   P_200214103155  3.498000
2 63.207  0.5 P_200214103155  6.161250
3 63.207  2   P_200214103155 10.420333
4 94.810  0   P_200214103155 15.852250
5 94.810  0.5 P_200214103155 10.553000
6 94.810  2   P_200214103155 10.441000
7 142.215 0   P_200214103155 17.495000
8 142.215 0.5 P_200214103155 38.332667
9 142.215 2   P_200214103155 40.320750

成对与成对不同。

成对只是意味着每个组都应该与其他组进行比较。

当您设置 paired=TRUE 时,每对条件将与配对 t 检验进行比较,这显然需要每个条件下的观察值数量具有相同的长度,以便单个观察值可以是配对。您确定要 paired=TRUE 吗?