How to style a choropleth map in the Customize

Map design Advanced cartography examples

This set of articles represents a recommended selection of advanced cartography examples.

  1. How to make custom map design in MapTiler Cloud
  2. How to style a retro map
  3. How to style a pop art map
  4. Map styled like a picture
  5. How to make an Oktoberfest map
  6. How to style a choropleth map in the Customize
  7. How to use MapTiler Ocean

MapTiler Countries dataset makes it easy to build a choropleth map where you connect geographically related data to countries, administrative or postal units, e.g. election maps, census data, and other statistical data. Read more about Countries if you need general information or see schema documentation.

There are two ways how to do it:

  • For simple use cases, we recommend using our Customize. The tool is part of your account in MapTiler Cloud. This article is about this method.
  • For a more complex analysis of tabular data, you should join them with the dataset using the JavaScript library. How to do it in MapLibre is described in this article.

Prepare MapTiler Countries for the Customize

1. Finding the Countries tileset

MapTiler Countries is available in MapTiler Cloud in the Tiles section.

countries_sat_1.png

2. Creating a style from scratch

To be able to visually edit this tileset, we need to create a style. It can be done by clicking on Create Style button located under the tileset preview.

countries_sat_2.png

3. Filling the name and description

After clicking on Create Style we will be shown a form where we can fill in the Title, Label, and Description of the new map. In this case, the title is Countries Satellite, the label is set to test, and the description is Satellite background with Countries tileset.

countries_sat_3.png

4. Entering into Customize

When a new map style is created, you can see that title, label, and description are successfully created as a new map Countries Satellite.To enter into Customize, click on Customize button.

countries_sat_4.png

5. Deleting unused layers

  • Click on the Layers (Alt + L) button on the left panel
  • Right Click on postal_polygon
  • Click on Delete
  • Delete also postal_point, postal_line, and administration_point countries_sat_5.png

6. Filtering France and Portugal country

  • Select administrative_polygon layer
  • Switch to the Data view
  • Set up a filter for iso_a2 on FR and PT
  • Set up a filter for level 0 countries_sat_6.png

7. Coloring the filtered countries

Set the color of administrative_polygon on #2F38B1 (in Style view)

countries_sat_7.png

8. Duplicating the layer

  • To create a supplement country with different colors, we need to duplicate the style layer and filter out France and Portugal
  • Right-click on administrative_polygon
  • Click on Duplicate countries_sat_8.png
  • Set the name of the duplicated layer on Europe (right-click on the layer and select Rename) countries_sat_9.png
  • Filter out the France and Portugal countries by setting up iso_a2 and continent values. countries_sat_10.png

9. Setting color for the Europe layer

Set the color of Europe layer on #468B5C (in Style view)

countries_sat_11.png

10. Filter out just the lines for the states (provinces)

  • Keep just the borders for provinces setting up the filter for administrative_line
  • Set filter as level = 1 countries_sat_12.png

11. Setting color for the administrative_line layer

Set the color of administrative_line layer on #80817E (in Style view)

countries_sat_13.png

12. Moving the layer on the top

Move the administrative_line layer on the top of the list to see the layer on the top of all features (Verticality tab)

countries_sat_14.png

13. Adding background satellite

  • For a better context, we can add satellite images as a background
  • Click on Data Sources (Alt + D) button on the left panel
  • Click on `+` sign (Alt + N) countries_sat_15.png

14. Selecting the Satellite tileset source

countries_sat_16.png

15. Adding a new layer

  • Click on the Layers (Alt + L) button on the left panel
  • Click on `+` sign (Alt + N)
  • Select Layer countries_sat_17.png
  • Select the Satellite Mediumres 2018 countries_sat_18.png
  • Keep the data format as Raster countries_sat_19.png
  • Add the name of the layer. In this case as satellite 2018 countries_sat_20.png
  • Move the satellite 2018 down in the list in the Verticality tab  countries_sat_21.png

16. Setting up the default view of the map

  • Under Settings (Alt + S) button at the left panel
  • Click on Set current view button
  • Click on Save countries_sat_22.png

17. Publishing the map

Click on Publish

countries_sat_23.png

18. Confirmation of the publishing

countries_sat_24.png

19. Close the Customize and use the link to share or implement it into your websites

countries_sat_26.png

Insert the map in a website

After saving and publishing this map in your account, you can add it to your web page. All needed info is available in the MapTiler Cloud account on the page with your map. Read how to insert maps in websites with a simple iframe.

Next steps

Continue to How to use MapTiler Ocean to learn how to leverage the MapTiler Ocean map style to the hilt!

MapTiler Countries dataset
MapTiler Countries
MapTiler Countries schema
Join MapTiler Countries with your own custom data and make a choropleth map