← Back to the hackathon home
Topic 13 of 18

DHIS2 Maps

Step by Step Guide: Building a Thematic Map, Saving It and Downloading It

Purpose of this guide

A chart shows how much and when, and a map shows where. This guide builds one thematic layer from an indicator, reads its legend, saves the map and turns it into a picture for a report. The example is ANC 3 coverage by district, and your malaria indicators work in exactly the same way. The map you save here goes on the dashboard in the next topic.

Step 1: Two Ways Into a Map

A map answers where, while a chart answers how much and when. There are two ways to start one. From the Data Visualizer, the selection you already made can be sent straight to the map. Or open the Maps app and build from nothing.

The visualisation type menu in the Data Visualizer with Open as Map at the bottom
Figure 1. Open as Map, at the foot of the type menu.
  1. 1Open as Map. Takes the data, period and organisation unit you chose in Topic 7 into the Maps app.
Click: Apps menu → Maps, or in the Data Visualizer, type menu → Open as Map
Step 2: Know the Maps Workspace

The Maps app is built from layers. One layer draws the data, another draws the background.

The Maps app with a thematic layer, its legend and the basemap panel
Figure 2. The Maps workspace.
  1. 1Add layer. Everything on the map starts here.
  2. 2The layer. Its name and the period it shows.
  3. 3The legend. The colour for each range, and how many units fall in it.
  4. 4Layer tools. Edit the layer, hide it, change how see through it is, and the menu for more.
  5. 5Basemap. The background map. OSM Light is the plainest and usually the best for reports.
  6. 6Map controls. Zoom, reset, full screen and search.
  7. 7File. New, open, save, share and delete.
  8. 8Download. Turns the map into a picture you can put in a report.
Step 3: Choose the Kind of Layer

Click Add layer. The list holds far more than the coloured districts most people expect.

The add layer menu with thematic, events, tracked entities, facilities, org units and the Earth Engine layers
Figure 3. The kinds of layer.
  1. 1Thematic. Districts or chiefdoms coloured by a value. This is the one this guide builds.
  2. 2Events. One dot per event, for tracker and event programmes.
  3. 3Facilities. The facilities themselves, with their icons.
  4. 4Org units. Just the boundaries, with no data.
  5. 5Population. From Earth Engine, useful as a denominator you do not have.
  6. 6Precipitation and temperature. Also from Earth Engine, which matters for malaria seasons.
Step 4: Build a Thematic Layer

The thematic layer window has five tabs, and they are the same four choices as a chart plus the styling.

The add new thematic layer window, with the data tab open and the ANC indicators listed
Figure 4. The thematic layer window.
  1. 1Data. What to map. Data elements, indicators, data sets or event data.
  2. 2Period. Last 12 months, this year, or a fixed month.
  3. 3Org Units. Choose a level, such as District or Chiefdom. This is what gets coloured.
  4. 4Style. The colours, the number of classes and the legend.
  5. 5Data Type. Indicators here, because a rate compares fairly between districts.
  6. 6The list. ANC 3 Coverage is the example. Click the arrow to move it to the right.
  7. 7Selected Items. One item per thematic layer.
  8. 8Add layer. Draws the layer on the map.
Map rates, not counts: a count makes the biggest district look worst every time. An indicator such as coverage puts every district on the same scale.
Step 5: Read the Map

The map colours every unit at the level you chose. Read the legend before reading the colours, because the ranges decide the story.

The thematic map of Sierra Leone with districts coloured by ANC 3 coverage
Figure 5. The finished thematic layer.
  1. 1The layer. Its name and period, which appear on the dashboard as well.
  2. 2The ranges. Low to great, with the number of districts in each range in brackets.
  3. 3The count. A zero in brackets means no district falls in that range.
  4. 4Transparency. Slide it when the basemap underneath needs to show through.
  5. 5Zoom. Plus, minus and reset. Double clicking a district zooms to it.
  6. 6Scale. Always check it before using the picture in a report.
Step 6: Save the Map

A map has to be saved before it can be put on a dashboard, exactly like a chart.

The file menu of the Maps app, with new, open, save, share and delete
Figure 6. The File menu.
  1. 1File. Opens this menu.
  2. 2Save. Saves changes to a map that already has a name.
  3. 3Save as. Makes a new map, which is what you want the first time.
  4. 4Get link. A link straight to this map, useful in an email.
  5. 5Delete. Removes the map for everyone it was shared with.
The save map as window with empty name and description
Figure 7. The save window.
The save map as window with a name and a description filled in
Figure 8. A name that says what it shows.
  1. 1Name. What it shows, the level and the period, for example ANC 3 Coverage by district, last 12 months.
  2. 2Description. One line on what the map is for. It appears beside the map on the dashboard.
  3. 3Save. Saves the map, ready for the dashboard.
Step 7: Download the Map as a Picture

For a report or a slide, turn the map into an image. Download mode adds the parts a printed map needs.

Download mode of the Maps app, with the options for name, description, legend, overview map and north arrow
Figure 9. Download mode.
  1. 1Show map name. The title on the picture.
  2. 2Show legend. Never leave this out. A map without a legend cannot be read.
  3. 3Show overview map. The small map that says where in the world this is.
  4. 4Show north arrow. With four positions to choose from.
  5. 5Download. Saves the picture to your computer.
  6. 6The title and description. Taken from what you typed when saving.
  7. 7The legend. Both layers appear, so remove the ones you do not need first.
Step 8: When the Map Looks Wrong
What you seeWhyWhat to do
Selected org units: no coordinates foundThe units you chose have no boundaries or points storedChoose a level that has boundaries, such as District or Chiefdom
The whole country is one colourThe ranges are too wide, or only one unit has dataChange the classes in the Style tab, or check the period
Every district looks badA count is being mapped instead of a rateMap an indicator, as in Topic 6
The legend ranges make no senseThe automatic classes do not suit the dataSet your own ranges, or use a legend made in the Maintenance app
Nothing is drawn at allThere is no data for that periodOpen the same selection as a pivot table in Topic 7 and check the numbers exist
Before you present a map: say out loud what the colours mean. If that takes more than one sentence, simplify the map rather than the sentence.

Final Checklist