A few days ago I built a dashboard (using
flexdashboard) to show some
plotly graphs and it worked perfectly fine. But today when I run the dashboard all the graphs are blank.
Triying some plots in the console I figured out that the problem is with
plotly as it works well using
ggplot2 and R Base graphics, but when I try to plot something simple using
library(ggplot2) library(plotly) plot_ly(x = ~rnorm(50), type = "histogram")
It gives me a blank panel:
And sometimes, for example with this:
library(ggplot2) library(plotly) plot_ly(data = iris, x = ~Sepal.Length, y = ~Petal.Length)
It shows this error:
No trace type specified: Based on info supplied, a 'scatter' trace seems appropriate. Read more about this trace type -> https://plot.ly/r/reference/#scatter No scatter mode specifed: Setting the mode to markers Read more about this attribute -> https://plot.ly/r/reference/#scatter-mode
I don't know what the problem is, does somebody know?
(Also I have RStudio updated to the latest version (
R version 3.6.3 (2020-02-29)) and all the packages as well)