Gpedia:Coloring cartographic maps

Jump to navigation Jump to search

It indicates how to give color to geographic areas (common geopolitical delimitations: nations, regions, etc.).

With the following steps:

  • Choose the colors to paint the areas.
  • Choose for one of two possibilities:
    • Paint the areas of a blank map.
    • Indicate that areas are still painted (only for maps of the world).

Choose the colors

We can find two main types of area maps:

  1. Qualitative data. For example: countries belonging to the NATO and others.
  2. Quantitatively grouped data. For example: countries with a low, medium or high population density.

One question to take into account is the choice of colors, in order to facilitate it, the Cynthia Brewer creates a color palettes, which are shown below.

These pallets are useful:

  • When there is enough qualitative data.
  • For quantitatively grouped data.

Brewer's color palettes

Valid names and full color representation for each palette. Moving the mouse cursor over each box the color number appears.

Sequential (1-9)
  • YlGn
                                       
  • YlGnBu
                                       
  • GnBu
                                       
  • BuGn
                                       
  • PuBuGn
                                       
  • PuBu
                                       
  • BuPu
                                       
  • RdPu
                                       
  • PuRd
                                       
  • OrRd
                                       
  • YlOrRd
                                       
  • YlOrBr
                                       
  • Purples
                                       
  • Blues
                                       
  • Greens
                                       
  • Oranges
                                       
  • Reds
                                       
  • Greys
                                       
Divergent (1-11)
  • PuOr
                                               
  • BrBG
                                               
  • PRGn
                                               
  • PiYG
                                               
  • RdBu
                                               
  • RdGy
                                               
  • RdYlBu
                                               
  • Spectral
                                               
  • RdYlGn
                                               
Qualitative (1-8/12)
  • Accent
                                   
  • Dark2
                                   
  • Paired
                                                   
  • Pastel1
                                       
  • Pastel2
                                   
  • Set1
                                       
  • Set2
                                   
  • Set3
                                                   


To present some specific colors will help the template {{BrewerColors}}.

Possibility 1: Paint the areas

To do this, it is always absolutely advisable (and easier) to do so in SVG format, rather than photo retouching programs. To edit SVG files, we have a free and open source program: Inkscape.

Find blank maps to paint

We can start from pre-existing SVG maps, some samples, with the links below (in Commons) where you can find many others, this (due to the indexation deficits inherent in the large number of existing files) it is better to do a search from the Search Wikimedia Commons input:

You can find here more SVG blank maps in Commons.

How to paint in examples

In the two examples that follow, we will use a blank map (SVG, as it could not be otherwise) of the world:

BlankMap-World.svg

Qualitative data

This is the easy case, and here, as in the example in the worldwide distribution of military alliances, we will choose 4 colors:

With {{BrewerColors|Set1|4|a}}, that shows:     #e41a1cff       #377eb8ff       #4daf4aff       #984ea3ff  

In fact, in the qualitative data the Brewer palettes are less necessary.

Once loaded this drawing in Inkscape, suppose you want to paint France of the indicated red color. That is why it is necessary to select it, and now, France, has like the other states, has been painted with a default gray color:

Inkscape FranceSelected.png

Go to the color palette (Fill and Stroke with Shift + Ctrl + F), where at the bottom (of the first page) you can see, which France has assigned a gray tone (b9b9b9ff):

Inkscape FillColor1.png

Then you just have to change for the red color of the palette (e41a1cff):

Inkscape FillColor2.png

This will allow us to paint the world map with these 4 colors. For those not very familiar with Inkscape, it is worth remembering that, to go faster, you can select several countries at the same time.

Military Alliances BrewerColors.svg
Preparing the code from the legend of the map

Using {{BrewerColorLegends}}:

The following template

{{BrewerColorLegends|Set1|4|
|--Not assigned to an alliance
| North Atlantic Treaty Organization (NATO)
| Union of South American Nations
| Council for Peace and Security
| Shanghai Cooperation Organization (SCO)}}

will show us what the legends will look like and show us the code to attach:

  • Not assigned to an alliance
  • North Atlantic Treaty Organization (NATO)
  • Union of South American Nations
  • Council for Peace and Security
  • Shanghai Cooperation Organization (SCO)
  •  {{legend|#b3b3b3|Not assigned to an alliance}}
     {{legend|#e41a1c|North Atlantic Treaty Organization (NATO)}}
     {{legend|#377eb8|Union of South American Nations}}
     {{legend|#4daf4a|Council for Peace and Security}}
     {{legend|#984ea3|Shanghai Cooperation Organization (SCO)}}
    

    Finally, modifying the code:

    [[File:Military_Alliances_BrewerColors.svg|270px|thumb|left|
     {{legend|#b3b3b3|Not assigned to an alliance}}
     {{legend|#e41a1c|North Atlantic Treaty Organization (NATO)}}
     {{legend|#377eb8|Union of South American Nations}}
     {{legend|#4daf4a|Council for Peace and Security}}
     {{legend|#984ea3|Shanghai Cooperation Organization (SCO)}}]]

    the result will be:

      Not assigned to an alliance
      North Atlantic Treaty Organization (NATO)
      Union of South American Nations
      Council for Peace and Security
      Shanghai Cooperation Organization (SCO)

    Data grouped quantitatively

    Suppose we want to make a map of the world on the Human Development Index, with 4 progressive categories: Low, Medium, High and Very high. With {{BrewerColors|Blues|4|a}}, you get:     #eff3ffff       #bdd7e7ff       #6baed6ff       #2171b5ff  

    With these colors we will paint the blank map:

    2017 UN Human Development Report Quartiles.svg
    Preparing the code from the legend of the map

    Using {{BrewerColorLegends}}, the next template {{BrewerColorLegends|Blues|4|15em|Low|Middle|High|Very high}} will show us how the legends will remain and show us the code to attach. We have chosen a 15em column width unlike the previous one since the text of each element is very short:

  • Low
  • Middle
  • High
  • Very high
  • {{div col|colwidth=15em}}
     {{legend|#eff3ff|Low}}
     {{legend|#bdd7e7|Middle}}
     {{legend|#6baed6|High}}
     {{legend|#2171b5|Very high}}
    {{div col end}}
    

    Finally, once the code is copied to the image footer:

      Low
      Middle
      High
      Very high

    Possibility 2: Indicate that the areas are painted

    Currently only available for maps of the world.

    The article is a derivative under the Creative Commons Attribution-ShareAlike License. A link to the original article can be found here and attribution parties here. By using this site, you agree to the Terms of Use. Gpedia Ⓡ is a registered trademark of the Cyberajah Pty Ltd.