Skip to content
Prev 6817 / 29559 Next

need to create US map with colors by state

Try this:

library(help = maps)

# show polygon names in order
map("state", fill = TRUE, plot = FALSE, names = TRUE)

# make first polygon have color 1, second 2, etc.
map("state", fill = TRUE, col = 1:63)
On Thu, Nov 5, 2009 at 12:14 PM, Mark Kimpel <mwkimpel at gmail.com> wrote: