Use mapbox.
Arguments
- e
An
echarts4r
object as returned bye_charts
or a proxy as returned byecharts4rProxy
.- token
Your mapbox token from mapbox.
- ...
Any option.
Examples
if (FALSE) {
url <- paste0(
"https://echarts.apache.org/examples/",
"data-gl/asset/data/population.json"
)
data <- jsonlite::fromJSON(url)
data <- as.data.frame(data)
names(data) <- c("lon", "lat", "value")
data |>
e_charts(lon) |>
e_mapbox(
token = "YOUR_MAPBOX_TOKEN",
style = "mapbox://styles/mapbox/dark-v9"
) |>
e_bar_3d(lat, value, coord_system = "mapbox") |>
e_visual_map()
}