Error message in lme4::glmer: “ 'what' must be a character string or a function”

风流意气都作罢 提交于 2019-11-29 11:01:17

(expanded from comment).

Congratulations, you found a bug in lme4! This is fixed now:

https://github.com/lme4/lme4/commit/9c12f002821f9567d5454e2ce3b78076dabffb54

It is caused by having a variable called new in the global environment (deep in the guts of the code, lme4 uses do.call(new,...) and finds your variable new rather than the built-in function new).

You can install a patched version from Github using devtools::install_github() (but you'll need compilation tools etc.). Alternately, there is a very simple workaround -- just call your variable anything other than new (you can't just copy it, i.e. new2 <- new -- you also have to make sure the old version is removed (rm("new"))).

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!