This function generates colors for zones.
zb_color(z, palette = c("rings", "hcl", "dartboard"))
An `sf` object containing zones covering the region
Palette type, one of "hcl"
(a palette based on the HCL color space), "rings"
(a palette which colors the rings using the YlOrBr color brewer palette), "dartboard"
(a palette which resembles a dartboard)
A vector of colors
z = zb_zone(london_c(), london_a())
zb_color(z)
#> [1] "#FFF7BC" "#FEE391" "#FEE391" "#FEE391" "#FEE391" "#FEE391" "#FEE391"
#> [8] "#FEE391" "#FEE391" "#FEE391" "#FEE391" "#FEE391" "#FEE391" "#FEC44F"
#> [15] "#FEC44F" "#FEC44F" "#FEC44F" "#FEC44F" "#FEC44F" "#FEC44F" "#FEC44F"
#> [22] "#FEC44F" "#FEC44F" "#FEC44F" "#FEC44F" "#FE9929" "#FE9929" "#FE9929"
#> [29] "#FE9929" "#FE9929" "#FE9929" "#FE9929" "#FE9929" "#FE9929" "#FE9929"
#> [36] "#FE9929" "#FE9929" "#EC7014" "#EC7014" "#EC7014" "#EC7014" "#EC7014"
#> [43] "#EC7014" "#EC7014" "#EC7014" "#EC7014" "#EC7014" "#EC7014" "#EC7014"
#> [50] "#CC4C02" "#CC4C02" "#CC4C02" "#CC4C02" "#CC4C02" "#CC4C02" "#CC4C02"
#> [57] "#CC4C02" "#CC4C02" "#CC4C02" "#CC4C02" "#CC4C02" "#993404" "#993404"
#> [64] "#993404" "#993404" "#993404" "#993404" "#993404" "#993404" "#993404"
#> [71] "#662506" "#662506" "#662506" "#662506"
plot(z[, "circle_id"], col = zb_color(z))