Map - County polygons / boundaries - Create leaflet or static map of results of analysis
Source:R/MAP_FUNCTIONS.R
mapfastej_counties.Rd
Map - County polygons / boundaries - Create leaflet or static map of results of analysis
Arguments
- mydf
something like ejamit(fips = fips_counties_from_statename("Kentucky"), radius = 0)$results_bysite
- colorvarname
colname of indicator in mydf that drives color-coding (or alternatively, colorvarname = "green" means a single specific color for all, like "green")
- colorfills
= c('yellow', 'orange', 'red')
- colorlabels
= c(80, 90, 95)
- colorbins
= c(80, 90, 95)
- colorpalette
= c("yellow", "yellow", "orange", "red")
- static_not_leaflet
set TRUE to use
map_shapes_plot()
instead ofmap_shapes_leaflet()
- main
title for map
- ...
passed to map_shapes_plot() if relevant
Value
leaflet html widget (but if static_not_leaflet=T, returns just shapes_counties_from_countyfips(mydf$ejam_uniq_id))
Examples
if (FALSE) { # \dontrun{
fips_ky <- fips_counties_from_statename("Kentucky")
x <- ejamit(fips = fips_ky, radius = 0)
mapfastej_counties(x$results_bysite)
} # }
# map_shapes_leaflet(shapes = shapes_counties_from_countyfips(fips_ky))