Quantcast
Channel: Active questions tagged r - Stack Overflow
Viewing all articles
Browse latest Browse all 201941

How to store Highcharter maps in order to use them without an Internet connection?

$
0
0

Usually, as the hcmap() function explains, the representation of the map gets downloaded on each Shiny session, unless we change the download_map_data parameter.

If we set it to FALSE, then it tries to fetch it locally.

In order to download the maps, we have the download_map_data() function.

But while trying to merge it all together, I can not make it work as expected.

Example:

require(dplyr) 
data("USArrests", package = "datasets")
USArrests <- mutate(USArrests, "woe-name" = rownames(USArrests))
usa_map <- download_map_data(url = "countries/us/us-all", showinfo = F)

hcmap(map = usa_map, data = USArrests,
      joinBy = "woe-name", value = "UrbanPop",
      name = "Urban Population", download_map_data = F)

It throws an error. How is the preferred manner to load the map locally?


Viewing all articles
Browse latest Browse all 201941

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>