Skip to content

World Heat/Rainbow Map

2 messages · Lorenzo Isella, ilai

#
Dear All,
I would like to do the following: make a plot of the world and color a few selected states.
Some states have an associated scalar (i.e a simple number) and I would like to paint them using a heat map and show legend for the color map in the plot. One or two states do not have any number associated to them and are simply colored/filled according to a distinctive pattern that I choose. 
To fix the ideas, imagine the following situation in which

(1) the US are striped (or filled with any pattern not in the heat map) and no number is associated to them;
(2) China, France and UK have associated values 54, 32 and 14 and I would like to "paint" them according to a heat map.
(3) The other states can be left blank, or I can pretend that there is a "zero" associated to them.

I made some attempts with map(world), but so far I have been banging my head against the wall.
Any suggestion is appreciated.
Cheers

Lorenzo
#
Figure 13.10 in "Lattice: Multivariate Data Visualization with R"
might give you some ideas
http://lmdvr.r-forge.r-project.org/figures/figures.html

On Sun, Feb 19, 2012 at 9:05 AM, Lorenzo Isella
<lorenzo.isella at gmail.com> wrote: