Description Usage Arguments Value Examples
Add weather data to leaflet map.
1 2 |
map |
|
data |
owm data |
lng |
numeric vector of longitudes
(if |
lat |
numeric vector of latitudes
(if |
icon |
vector of owm icon names (usually included in weather column of owm data) |
template |
template in the form of |
popup |
vector containing (HTML) content for popups,
skipped in case parameter |
... |
see |
updated map object
1 2 3 4 5 6 7 8 9 10 11 | ## Not run:
owm_data <- find_city("Malaga", units = "metric") %>%
owmr_as_tibble()
map <- leaflet() %>% addTiles() %>%
add_weather(
owm_data,
template = "<b>{{name}}</b>, {{temp}}<c2><b0>C",
icon = owm_data$weather_icon
)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.