Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- renderLeaflet ({
- pal8 <- c("#FFFFE5", "#D9F0A3", "#78C679", "#006837")
- bins=quantile(mapdata_1()$Per), na.color = "#808080", alpha = FALSE, reverse = F)
- pal <- colorFactor(palette = pal8, domain =NULL, levels=(mapdata_1()$cat), ordered = TRUE, na.color = "#808080", alpha = FALSE, reverse = F)
- leaflet (mapdata_()) %>%
- addProviderTiles("CartoDB.Positron") %>%
- clearControls() %>%
- clearShapes()%>%
- addPolygons(fillColor = ~pal(cat)) %>%
- addTiles() %>%
- setView(-82.706838, 40.358615, zoom=7) %>%
- addLegend(position = "bottomright",
- values = ~cat,
- pal = pal,
- title = (paste("%",input$Age_Group_map, input$sex_map, "in", input$Year_map)) ,
- labFormat = labelFormat(
- ))
- })
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement