Plotly Maps Not Rendering in R

后端 未结 2 1515
我寻月下人不归
我寻月下人不归 2021-01-05 11:13

I have successfully installed the plotly library for R.

To get started, I followed their Getting Started for R guide and directly copied the code from several plots

相关标签:
2条回答
  • 2021-01-05 11:49

    I have had similar troubles with plotly rendering choropleth maps in the RStudio Viewer. Even copying the code exactly as provided in your links to the ployly website gave me just a title and legend, but no map.

    However, when I expanded the Viewer using the "Show in new window" button, the choropleth opens up in my web brower fully rendered.

    This leads me to believe that the issue is either:

    1. Something to do with the plotly package itself not correctly working within RStudio's environment (doubt it's this) or,
    2. It's just one of those instances where the plot doesn't render because the size of the Viewer window is too small. I have that happen if I run something like "pairs" on a large data frame with a lot of correlations. It doesn't show in the viewer unless I expand it to a larger size or render it in a browser window.

    I would like to know if there are any settings either in RStudio or in the packages themselves that may fix this.

    EDIT: I do not encounter this issue when rendering the plot on my laptop -- just my desktop. I believe both are running the latest R/RStudio versions so I'm not sure why one renders and one does not.

    0 讨论(0)
  • 2021-01-05 11:55

    You currently need an internet connection to view the scattergeo trace type -- https://github.com/ropensci/plotly/issues/356

    0 讨论(0)
提交回复
热议问题