geojson leaflet r

Solutions on MaxInterview for geojson leaflet r by the best coders in the world

showing results for - "geojson leaflet r"
Ange
05 Aug 2019
1labels <- sprintf(
2  "<strong>%s</strong><br/>%g people / mi<sup>2</sup>",
3  states$name, states$density
4) %>% lapply(htmltools::HTML)
5
6m <- m %>% addPolygons(
7  fillColor = ~pal(density),
8  weight = 2,
9  opacity = 1,
10  color = "white",
11  dashArray = "3",
12  fillOpacity = 0.7,
13  highlight = highlightOptions(
14    weight = 5,
15    color = "#666",
16    dashArray = "",
17    fillOpacity = 0.7,
18    bringToFront = TRUE),
19  label = labels,
20  labelOptions = labelOptions(
21    style = list("font-weight" = "normal", padding = "3px 8px"),
22    textsize = "15px",
23    direction = "auto"))
24m