I am trying to create an interaction plot from a multilevel model using sjPlot in RStudio. When I set limits on the y-axis, one of the regression lines is cut off. There are no data points beyond the limits. I am receiving the warning: "Scale for y is already present. Adding another scale for y, which will replace the existing scale."
Thanks for any advice.
The model is as follows:
model1b <- lmer(NEGAFF ~ DIST_PC*EVINT_PC + (1 + DIST_PC + EVINT_PC | UUID), data = DATA_POOLED)
Below is the code for the plot:
plot_model1b_inv <- plot_model(model1b, type = "pred", #can use the same model type as before from sjplot
terms = c("EVINT_PC", "DIST_PC
[-0.24, 0.24]"),
title = " ",
axis.title = c("Stressor Intensity", "Momentary Negative Affect"),
legend.title = "Spontaneous Distraction Use",
show.data = TRUE, dot.size = 0.6, jitter = 0.2,
ci.lvl = 0.95, colors = Dark2) + apatheme + xlim(-1,1) + ylim(0,1) + theme(legend.position = "bottom")