I want to visualize actual dates format instead of numbers (transformed by default) using ggplotly graphs when I put the cursor over the data points. Thanks in advance!
Here is a simple example:
require(plotly)
require(ggplot2)
x <- c("01/01/2007","04/03/2008","28/11/2008","13/06/2009")
y <- c(25, 50, 75, 100)
x_lab <- "date"
y_lab <- "score"
(mydata <- as.data.frame(cbind(x,y)))
mydata$x <- as.Date(mydata$x, "%d/%m/%Y")
ggplot(mydata, aes(x=x, y=y)) +
geom_point()
ggplotly()