Unable to plot interaction of plm output
Hello. I'm trying to plot the interaction of a plm output, but it keeps giving me the following error. I've tried uninstalling and reinstalling R and the packages therein, but to no avail. Would you be so kind as to help figure out what is happening? Your help is much appreciated. Thank you!
Model run: plm(data = data, formula = y ~ x1 + x2 + x1*x2, model = "within", index = c("grp", "year")))
Error: ~does not appear to be a one- or two-sided formula. y does not appear to be a one- or two-sided formula. x1 + x2 + x1 * x2 does not appear to be a one- or two-sided formula. Backtrace:
- interactions::interact_plot(...)
- jtools::get_data(model, warn = TRUE, ...)
- jtools:::get_lhs(formula)
I will look into this. Generating predictions from such models can be a little more complicated than it appears and I don't want to give bad results.