Hi everyone, I have a question concerning the coloring of polygons:
How can I color polygons (in this case a map with all the world’s countries) by population/normalized levels using RGBColor[{x,0,0}]?
This is my code so far (and yes, I’m aware it’s pretty bare bones and probably bad too):
I already have a list of normalized population values (China being 1, India 0.896849 etc.), but I don’t know how to properly implement that in the aforementioned RGBColor[].
Assuming one has already built the lists of colors and corresponding polygons, Transpose can help to match them up, as in Transpose[{listOfColors, listOfPolygons}]. Try for example the following (5 is just a random scaling factor):
For a nice color contrast you need to adjust somehow for the drastic differences between countries’ populations. You could do something like the following (where “tone” is control to affect the color contrast):