我的数据在这里描述当拟合重复测量方差分析时,什么会导致aov中的“ Error()模型为奇异误差”?
我试图使用来查看交互的效果,lmer
所以我的基本情况是:
my_null.model <- lmer(value ~ Condition+Scenario+
(1|Player)+(1|Trial), data = my, REML=FALSE)
my.model <- lmer(value ~ Condition*Scenario+
(1|Player)+(1|Trial), data = my, REML=FALSE)
运行anova
会给我带来显着的结果,但是当我尝试考虑随机斜率((1+Scenario|Player)
)时,模型将失败,并显示以下错误:
Warning messages:
1: In commonArgs(par, fn, control, environment()) :
maxfun < 10 * length(par)^2 is not recommended.
2: In optwrap(optimizer, devfun, getStart(start, rho$lower, rho$pp), :
convergence code 1 from bobyqa: bobyqa -- maximum number of function evaluations exceeded
3: In commonArgs(par, fn, control, environment()) :
maxfun < 10 * length(par)^2 is not recommended.
4: In optwrap(optimizer, devfun, opt$par, lower = rho$lower, control = control, :
convergence code 1 from bobyqa: bobyqa -- maximum number of function evaluations exceeded
5: In checkConv(attr(opt, "derivs"), opt$par, ctrl = control$checkConv, :
Model failed to converge with max|grad| = 36.9306 (tol = 0.002)
6: In checkConv(attr(opt, "derivs"), opt$par, ctrl = control$checkConv, :
Model failed to converge: degenerate Hessian with 1 negative eigenvalues
或者,如果它在多次迭代后仍无法收敛(我将其设置为100 000
),并且在此之后得到了相同的结果50k
,100k
这意味着它非常接近实际值,只是没有达到它。那么我可以这样报告我的结果吗?
请注意,当我将迭代次数设置得很高时,我只会收到以下警告:
Warning messages:
1: In checkConv(attr(opt, "derivs"), opt$par, ctrl = control$checkConv, :
Model failed to converge with max|grad| = 43.4951 (tol = 0.002)
2: In checkConv(attr(opt, "derivs"), opt$par, ctrl = control$checkConv, :
Model failed to converge: degenerate Hessian with 1 negative eigenvalues