0

我正在比较两个模型,以查看特定交互(会话组)是否重要。Mod1 是完整模型,Mod2 是完整模型减去会话组交互。

mod1 = lmer(accuracy ~ session + trialtype + group + session*trialtype +     
session*group + session*group*trialtype + trialtype*group + 
(1+trialtype|subject), data=data, REML=FALSE)

mod2 = lmer(accuracy ~ session + trialtype + group + session*trialtype + 
session*group*trialtype + trialtype*group + (1+trialtype|subject), 
data=data, REML=FALSE)

这是我的相同输出:

Data: data
Models:
mod1: accuracy ~ session + trialtype + group + session * trialtype + 
mod1:     session * group + session * group * trialtype + trialtype * 
mod1:     group + (1 + trialtype | subject)
mod2: accuracy ~ session + trialtype + group + session * trialtype + 
mod2:     session * group * trialtype + trialtype * group + (1 + trialtype 
| 
mod2:     subject)
     Df    AIC    BIC  logLik deviance Chisq Chi Df Pr(>Chisq)
mod1 27 4026.4 4150.3 -1986.2   3972.4                        
mod2 27 4026.4 4150.3 -1986.2   3972.4     0      0          1

代码有问题,我只是想不通。此外,在查看主要效果/交互时,这是比较 2 个模型的正确方法吗?我从来没有上过传销课程,所以我一直在自学。

先感谢您!

另外:如果有帮助,这里是我的数据的一个子集,如建议的那样:

subject  accuracy group session trialtype
1        5 1.0000000     1       2        BX
2       93 0.8000000     2       2        BX
3       12 0.8000000     2       2        BY
4       85 1.0000000     3       1        BX
5       21 1.0000000     3       2        AX
6       54 0.9900000     2       2        AX
7        2 0.8000000     1       1        BY
8       36 0.9142857     2       1        BX
9        1 1.0000000     1       2        AY
10       4 0.7900000     1       2        BY
4

0 回答 0