Learn R Programming

antaresViz (version 0.18.3)

addShadows: Add a shadow to map layers

Description

This function adds a shadow to every svg element added to a leaflet map. It can greatly improve the lisibility of the map.

Usage

addShadows(map)

Value

The modified map object

Arguments

map

A leaflet map object.

Examples

Run this code
require(leaflet)
require(leaflet.minicharts)

leaflet() %>%
  addTiles() %>% 
  addFlows(0, 0, 1, 0, col= gray(0.9)) %>%
  addCircleMarkers(c(0, 1), c(0, 0), color = "white", fillOpacity = 1, stroke = FALSE) %>%
  addShadows()

Run the code above in your browser using DataLab