Styling vector layers with categories and classes
Give a layer a single symbol, colour features by category, classify numbers into graduated classes, and add labels.
You will learn
- Use single symbol, categorized and graduated renderers.
- Choose a classification method and a colour ramp.
- Label features with a field.
Prerequisites
Data for this tutorial
Wards (synthetic) Download wards.geojson
- Format
- GeoJSON
- Geometry
- Polygon
- CRS
- EPSG:32643 (WGS 84 / UTM zone 43N)
- Content
- 84 wards (31 peri-urban, 19 rural, 34 urban), 333,497 residents
- In Orbis
- Browser panel ▸ Tutorial sample data (synthetic) ▸ Wards, or Load complete tutorial pack.
Fields used in the tutorials
| Field | Type | Description |
|---|---|---|
ward_id | text | Ward code W01 to W84. |
ward_name | text | Ward name. |
zone | text | urban, peri-urban or rural. |
population | integer | Residents. |
households | integer | Households. |
area_km2 | real | Ellipsoidal area in km². |
density_km2 | real | Persons per km². |
literacy_rate | real | Literate share, per cent. |
Land use 2019 and 2024 (synthetic) Download landuse_2024.geojson
- Format
- GeoJSON (also landuse_2019.geojson)
- Geometry
- Polygon
- CRS
- EPSG:32643 (WGS 84 / UTM zone 43N)
- Content
- 61 polygons (2024), 50 polygons (2019)
- In Orbis
- Browser panel ▸ Tutorial sample data (synthetic) ▸ Land use 2024, or Load complete tutorial pack.
Fields used in the tutorials
| Field | Type | Description |
|---|---|---|
lu_id | text | Polygon identifier. |
class | text | built-up, cropland, forest, water or scrub. |
code | integer | Class code 1 to 5. |
year | integer | 2019 or 2024. |
area_ha | real | Ellipsoidal area in hectares. |
Licence: CC0 1.0. All tutorial data is synthetic and generated by Orbis. About the datasets
The task
A map communicates through its symbols. You will colour the land-use polygons by class and the wards by population density, and label the wards with their names.
Steps
- Add Land use 2024 and Wards. Click Land use 2024 (synthetic) and open the Style tab in the right panel (or press F7).
- Choose Categorized, then
classas Value field. Orbis creates one class per value (built-up, cropland, forest, water, scrub) with the number of features in each. Click a colour box to change a colour, or untick a class to hide it.
Click Wards (synthetic). Choose Graduated,
density_km2as Numeric field, Quantile (equal count) as Method,5Classes and a sequential Colour ramp. Each class is listed with its colour and the number of features drawn in that colour. The note under Method states how that method computes breaks. Type a new upper value to move a break: the value must stay between the neighbouring breaks, and a feature exactly on a break is drawn in the next class. The last class has no upper cutoff.
Graduated classes of population density.
- Open the Labels section, tick Label features and choose
ward_nameas Label field. Adjust the size, the halo and Avoid overlapping labels as needed.
Expected result
Land use is drawn with one colour per class, the wards from light (low density) to dark (high density), with their names as labels.
Common mistakes
- Graduated on a text field. Graduated classes need a numeric field; text values are drawn with the "other" colour.
- Too many categories. A field with hundreds of distinct values (such as an id) makes an unreadable legend. Categorize by a field with few values.
Troubleshooting
- A colour does not change. Some classes may be hidden or the layer opacity may be low; check Layer opacity at the end of the Style tab.
- Labels are missing. Labels that would overlap are hidden; zoom in or untick Avoid overlapping labels.