You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Using plot_prediction() with categorical variables and vcov = FALSE results in an error message (setting vcov = TRUE works fine):
library(marginaleffects)
mod= lm(Sepal.Length~Species, data=iris)
plot_predictions(mod, by="Species", vcov=FALSE)
#> Error in `ggplot2::geom_point()`:#> ! Problem while computing aesthetics.#> ℹ Error occurred in the 1st layer.#> Caused by error in `.data[[NULL]]`:#> ! Must subset the data pronoun with a string, not `NULL`.
Tested using the latest Git version.
This is especially a problem for glmmTMB models, where plot_predictions() tells us that we should use vcov = FALSE (though it actually seems to work fine with vcov = vcov(mod) for linear Gaussian models like this one).
The text was updated successfully, but these errors were encountered:
It's probably just a question of inserting more if/else statements or use a do.call() to ensure that we don't feed useless arguments to ggplot::aes(). The problem will probably arise in the next code block as well with continuous x-axis, but it should be a pretty easy fix. (But start of semester is upon us at my university, so I'll do my best...)
Using
plot_prediction()
with categorical variables andvcov = FALSE
results in an error message (settingvcov = TRUE
works fine):Tested using the latest Git version.
This is especially a problem for glmmTMB models, where
plot_predictions()
tells us that we should usevcov = FALSE
(though it actually seems to work fine withvcov = vcov(mod)
for linear Gaussian models like this one).The text was updated successfully, but these errors were encountered: