Closed
Description
I think I might have found a bug associated with the ggplotly
function in the plotly
package.
In the following bit of code, the result works for n = 9 but not n >= 10.
Can anybody suggest a work around, or at least a reason for the bug?
require(data.table)
require(plotly)
require(ggplot2)
n <- 10
jj <- CJ(week=c(1:n),day=c('Sun','Mon','Tue','Wed','Thu','Fri','Sat'),hour=c(0:23))
jj[,day:=factor(day,levels = c('Sun','Mon','Tue','Wed','Thu','Fri','Sat'))]
jj[,n:=rnorm(nrow(jj))]
p1 <- ggplot(jj,aes(x=hour,y=n))+geom_line()+facet_grid(week~day)
p1
p1 <- ggplotly(p1)
p1
Thanks,