Closed misea closed 2 years ago
But it works if you drop the "group" column created by tidy(lmer_model) before plotting
library(lme4) data("mtcars") m1 <- lm(mpg~wt+disp + cyl, data = mtcars) {dwplot(m1)} %>% add_brackets(list(c("G1", "wt", "wt"), c("G2", "disp", "disp"))) # Looks good m2 <- lmer(mpg~wt+disp+(1|cyl), data = mtcars) {dwplot(m2)} %>% add_brackets(list(c("G1", "wt", "wt"), c("G2", "disp", "disp"))) # Error: `by` can't contain join column `group` which is missing from LHS dev.off() # Now get rid of the group column created by tidying lmer models {dwplot(tidy(m2) %>% select(-group))} %>% add_brackets(list(c("G1", "wt", "wt"), c("G2", "disp", "disp"))) # Looks good again
The issue should have been fixed in the dev version.
But it works if you drop the "group" column created by tidy(lmer_model) before plotting