i want create geographical map of countries in europe can highlight of countries using particular system.
i have tried using library(maps) here cant find option plot whole of europa (and several relevant countries not included in package). have suggestion me on how is?
what this?
library(rworldmap) world <- getmap() europe <- world[world$admin %in% c("austria","belgium","bulgaria","croatia","cyprus","czech republic","denmark","estonia","finland","france","germany","greece","hungary","ireland","italy","latvia","lithuania","luxembourg","malta","netherlands","poland","portugal","romania","slovakia","slovenia","spain","sweden","united kingdom"), ] cols <- setnames(rep("yellow", length(europe$admin)), europe$admin) cols["france"] <- "blue"; cols["poland"] <- "red" plot(europe, col = cols) 
Comments
Post a Comment