I would like to know if it is possible to add a horizontal line with a hover text ability like the one in the screenshot below which will indicate the average value of the y-axis
library(plotly)
p <- plot_ly(data = iris, x = ~Sepal.Length, y = ~Petal.Length)