How can we make interaction plots for continuous variables in logistic regression?
The interaction is between two continuous variables. The plot is using Lag4 as the x-axis variable and then picking a couple of values of Volume to show how the relationship between Direction and Lag4 varies for different values of Volume. By default, the minimum and maximum of Volume are chosen. We can instead show the median and quartiles of Volume or the mean and standard deviation of Volume by using the mdrt.values argument (see the help for additional options). For example:
theme_set(theme_classic()) # Set ggplot theme
plot_model(m1, type="int", colors=rainbow(3), mdrt.values="quart")
plot_model(m1, type="int", colors=rainbow(3), mdrt.values="meansd")