Wikipedia:Coloring cartographic maps

{{Shortcut|WP:COLORMAP|WP:COLOURMAP}}

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.

{{center|Sequential (1-9)}}

{{colbegin|colwidth=20em}}

  • YlGn
    {{BrewerColors|YlGn|9}}
  • YlGnBu
    {{BrewerColors|YlGnBu|9}}
  • GnBu
    {{BrewerColors|GnBu|9}}
  • BuGn
    {{BrewerColors|BuGn|9}}
  • PuBuGn
    {{BrewerColors|PuBuGn|9}}
  • PuBu
    {{BrewerColors|PuBu|9}}
  • BuPu
    {{BrewerColors|BuPu|9}}
  • RdPu
    {{BrewerColors|RdPu|9}}
  • PuRd
    {{BrewerColors|PuRd|9}}
  • OrRd
    {{BrewerColors|OrRd|9}}
  • YlOrRd
    {{BrewerColors|YlOrRd|9}}
  • YlOrBr
    {{BrewerColors|YlOrBr|9}}
  • Purples
    {{BrewerColors|Purples|9}}
  • Blues
    {{BrewerColors|Blues|9}}
  • Greens
    {{BrewerColors|Greens|9}}
  • Oranges
    {{BrewerColors|Oranges|9}}
  • Reds
    {{BrewerColors|Reds|9}}
  • Greys
    {{BrewerColors|Greys|9}}

{{colend}}

{{center|Divergent (1-11)}}

{{colbegin|colwidth=20em}}

  • PuOr
    {{BrewerColors|PuOr|11}}
  • BrBG
    {{BrewerColors|BrBG|11}}
  • PRGn
    {{BrewerColors|PRGn|11}}
  • PiYG
    {{BrewerColors|PiYG|11}}
  • RdBu
    {{BrewerColors|RdBu|11}}
  • RdGy
    {{BrewerColors|RdGy|11}}
  • RdYlBu
    {{BrewerColors|RdYlBu|11}}
  • Spectral
    {{BrewerColors|Spectral|11}}
  • RdYlGn
    {{BrewerColors|RdYlGn|11}}

{{colend}}

{{center|Qualitative (1-8/12)}}

{{colbegin|colwidth=20em}}

  • Accent
    {{BrewerColors|Accent|8}}
  • Dark2
    {{BrewerColors|Dark2|8}}
  • Paired
    {{BrewerColors|Paired|12}}
  • Pastel1
    {{BrewerColors|Pastel1|9}}
  • Pastel2
    {{BrewerColors|Pastel2|8}}
  • Set1
    {{BrewerColors|Set1|9}}
  • Set2
    {{BrewerColors|Set2|8}}
  • Set3
    {{BrewerColors|Set3|12}}

{{colend}}

To present some specific colors will help the template {{tl|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:

BlankMap-Africa.svg|Africa‎

Afro-Eurasia location map with borders.svg|Afro-Eurasia

North_America_second_level_political_division_2_and_Greenland.svg|North America

Outline map of Central America.svg|Central America

Southamerica_blank.svg|South America

Antarctica_blank.svg|Antarctica

Asia_whole.svg|Asia

Blank map of Europe (with disputed regions).svg|Europe

Oceania_continents.svg|Oceania

BlankMap-World-Flattened.svg|World

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:

File: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 {{tlc|BrewerColors|Set1|4|a}}, that shows: {{BrewerColors|Set1|4|a}}

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:

File: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):

File:Inkscape FillColor1.png

{{-}}

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

File: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.

File:Military_Alliances_BrewerColors.svg

{{-}}

==== Preparing the code from the legend of the map ====

Using {{tl|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:

{{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)}}

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:

[[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)}}]]

{{-}}

== 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 {{tlc|BrewerColors|Blues|4|a}}, you get:

{{BrewerColors|Blues|4|a}}

With these colors we will paint the blank map:

File:2017 UN Human Development Report Quartiles.svg

{{-}}

==== Preparing the code from the legend of the map ====

Using {{tl|BrewerColorLegends}}, the next template {{tlc|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:

{{BrewerColorLegends|Blues|4|15em|Low|Middle|High|Very high}}

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

[[File:2017 UN Human Development Report Quartiles.svg|260px|thumb|left|

{{div col|colwidth=15em}}

{{legend|#eff3ff|Low}}

{{legend|#bdd7e7|Middle}}

{{legend|#6baed6|High}}

{{legend|#2171b5|Very high}}

{{div col end}}

]]

{{-}}

Possibility 2: Indicate that the areas are painted

{{main article|Template:Graph:Map}}

Currently only available for maps of the world.

Graphics tutorials

Category:Wikipedia tutorials