Guest User

Untitled

a guest
Jan 16th, 2019
43
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.52 KB | None | 0 0
  1. library(ROpenWeatherMap)
  2. library(RCurl)
  3. library(httr)
  4. library(jsonlite)
  5. library(leaflet)
  6. library(mapview)
  7. library(owmr)
  8. library(raster)
  9. openWeatherPlugin <- htmlDependency(
  10. "Leaflet.OpenWeather",
  11. "1.6.0",
  12. src = normalizePath(path = getwd()),
  13. script = "www/js/leaflet-openweathermap.js"
  14. )
  15. leaflet() %>%
  16. addTiles() %>%
  17. registerPlugin(openWeatherPlugin) %>%
  18. onRender("
  19. function(el, x){
  20. L.OWM.clouds({showLegend: true, opacity: 0.5, appId: 'AppID'}).addTo(this);
  21. }
  22. ")
Add Comment
Please, Sign In to add comment