inst/api-reference/line-layer.R

map <- geojsonsf::geo_melbourne %>%
  as_mapbox_source() %>%
  mapboxer(center = c(144.9624, -37.8105), zoom = 11, pitch = 45) %>%
  add_navigation_control() %>%
  add_line_layer(
    line_color = "red",
    line_width = 2
  )

if (interactive()) map

Try the mapboxer package in your browser

Any scripts or data that you put into this service are public.

mapboxer documentation built on Nov. 8, 2020, 4:21 p.m.