0

I have downloaded RCharts by doing the following:

require(devtools)
require(stringi)
install_github('rCharts', 'ramnathv')
library(rCharts)

My dataset is as follows:

Country<-c('ANTARCTICA','ARMENIA','CHINA','UNITED STATES','BRAZIL')
Pay<-c(20,50,100,13,43)
mapping<-data.frame(Country,Pay)

head(mapping)

        Country Pay
1    ANTARCTICA  20
2       ARMENIA  50
3         CHINA 100
4 UNITED STATES  13
5        BRAZIL  43

I want to create an interactive R Chart (NOT IN SHINY) where it is a world map and the colors represent the "Pay" when hovering over each country.

Here is an example but it is just with the United States by State. My goal is to get a world map and do it by country instead.

http://rmaps.github.io/blog/posts/animated-choropleths/

ekstroem
  • 5,957
  • 3
  • 22
  • 48
analytics
  • 149
  • 1
  • 9
  • I think you should use `rMaps` for this if you want something like the map. See https://github.com/ramnathv/rMaps – ekstroem Sep 24 '15 at 19:47
  • or `leaflet` (which can do what you need quite well) – hrbrmstr Sep 24 '15 at 19:48
  • Could you provide an example with my reproducible data above with either leaflet and/or rMaps? I feel like it won't read it correctly because my countries are in all caps and I am not really following the process on how to do it on the link – analytics Sep 24 '15 at 19:59
  • You could look at `gvisMap()` from the `googlevis` package [here](https://cran.r-project.org/web/packages/googleVis/googleVis.pdf). – aashanand Sep 24 '15 at 22:50

0 Answers0