Just an idea: try without saving in a variable:
diamonds %>%
ggplot(aes(carat, price))+ geom_bin2d()
Or alternatively, save in a variable, then call this variable:
plot_diamonds <- diamonds %>%
ggplot(aes(carat, price))+ geom_bin2d()
plot_diamonds
Try with quotes:
install.packages("hexbin")