首页 > 解决方案 > lmer:Anova 给出警告消息:在 beta - betaH 中:较长的对象长度不是较短对象长度的倍数

问题描述

我正在执行一个简单的一般线性混合模型,使用lmer. 我想知道养分处理地块之间的花卉访客丰度是否存在差异。我有 7 个营养处理地块,每个地块在 3 个块中复制一次。处理方法是:control, N, P, K, NPK, f_control, f_NPK. 块是:A, B, C.

我的数据如下所示:

totvisobs<-plots$tot_vis_obs_withesc
Treatment<-plots$Treatment
Block<-plots$Block
Block<-as.factor(Block)

和:

Block: Factor w/ 3 levels "A","B","C": 1 1 1 1 1 1 1 2 2 2 ...
Treatment: Factor w/ 7 levels "control","f_control",..: 1 4 7 5 6 2 3 1 4 7 ...
totvisobs: int [1:21] 63 57 38 150 97 38 83 53 69 47 ...

我的模型:

totvisobs_glmm<-lmer(totvisobs~Treatment+(1|blocks), REML = TRUE, data = plots)
Anova(totvisobs_glmm, test.statistic = "F")

这就是我得到的:

Analysis of Deviance Table (Type II Wald F tests with Kenward-Roger df)

Response: totbeeobs
              F Df Df.res   Pr(>F)   
Treatment 5.102  6     12 0.008054 **
---
Signif. codes:  0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1

警告消息:在 beta - betaH 中:较长的对象长度不是较短对象长度的倍数

我不知道我是否应该忽略这个警告。我一直在尝试一切来解决它,但我不知道该怎么做,因为我的数据看起来不错。有谁知道如何处理这个?

先感谢您!

丽珊娜

标签: rstatisticswarningslme4

解决方案


推荐阅读