if (FALSE) {
library(mapgl)
# Path to your local image file OR a URL to a remote image file
# that is not blocked by CORS restrictions
image_path <- "/path/to/your/image.png"
pts <- tigris::landmarks("DE")[1:100, ]
maplibre(bounds = pts) |>
add_image("local_icon", image_path) |>
add_symbol_layer(
id = "local_icons",
source = pts,
icon_image = "local_icon",
icon_size = 0.5,
icon_allow_overlap = TRUE
)
}
Run the code above in your browser using DataLab