Video - Visualizing Vector Data (Part 1): Symbology Styles

Catalogue number: Catalogue number: 89200005

Issue number: 2020009

Release date: February 25, 2020

QGIS Demo 9

Visualizing Vector Data (Part 1) – Symbology Styles - Video transcript

(The Statistics Canada symbol and Canada wordmark appear on screen with the title: "Visualizing Vector Data (Part 1) – Symbology Styles")

So now that we know how to edit the attributes and geometries of vector data, a complementary skill is using their fields for visualization. As we briefly introduced, these parameters can be set in the Layer Properties box. Today we'll focus on the Symbology tab learning:

The available styles and their application to different field types.

Then in a follow up video we'll show how to use rule-based visualizations, save and load created symbology files, and apply labelling schemes.

Before beginning let's discuss some considerations for visualization.

First - Are there established conventions for symbolizing the specific features in a layer? If there are multiple conventions - which is best aligned with the geographic location being visualized.

Second - Have you selected logical colour schemes for specific features?

Third - What is the appropriate style based on the field type.

And some additional factors that influence interpretability, such as:

  • Enhancing the contrast between different features
  • The number of features and level of detail relative to the scale to avoid creating overcrowded or oversimplified visualizations.

The simplest symbology edits can be done by right-clicking the layer, expanding Style and dragging on the colour wheel to change the colour. Using the white circle we can alter the specific hue and brightness. This is already an improvement for this layer, being immediately decipherable as water features.

Now lets explore the Single Symbol style, the default in QGIS, where a single colour is applied to all features - using the boundary layers. Specifically, we'll alter the styles to visualize both boundary levels simultaneously.

So opening the Layer Properties Box, in the Symbology tab, we can change the colour or transparency of the entire layer, as done with the hydrology layer, using these tabs. However, we want to change only the transparency of the Fill Color retaining the boundary outlines, so we'll click on Simple Fill and then Fill Colour. We can use the sliders on the right or the interactive selections in the various tabs to set the applied colour. For our purpose we will set the opacity to 0, making our layer fully transparent. We can use Apply to verify we're satisfied with the visualization and OK to finalize.

Now we'll repeat with the Census Division layer, going to Simple Fill and changing the outline width to 0.86 and then clicking on the colour – we'll alter it to Red to distinguish them from the subdivision boundaries. As seen in the Canvas, we can now visualize both boundaries simultaneously.

Alternatively we could have applied a categorized symbology, which enables us to symbolize discrete features, classes or categories within a specified field - selected in the Column drop-down. Using the Provincial Unique Identifier we can click Classify and Apply. So now each subdivision is coloured according to its province. We could switch this out for another categorical variable, like Census Division Names, hitting Classify – Yes and OK. So this offers an alternative means to visualize both boundary levels.

But due to the random colour ramp there are two issues:

  • The first being adjacent features may be assigned similar colours, complicating their distinction.
  • And the second, the applied colours may not enhance contrast between features or be aesthetically pleasing to interpret.

So we'll use some colour presets within the Symbology tab and the Topological Coloring tool in the Processing Toolbox to address these issues. The topological colouring tool is explicitly meant for symbolizing boundaries, and will ensure adjacent features are not assigned the same colour.

Within the tool we'll specify the Input layer, the number of colours to use and the Mode which determines how colours are assigned – and are explained in the tool description on the right. We’ll use Assigned Area, helpful given variations in the size of features in divisions and even more pertinent for the subdivision layer.

The tool outputs a new layer with the exact same properties as the input, except with one new field called “color id” which we can use for visualization. Selecting it from the drop-down, we will now expand Colour Ramp drop-down beside and select Create New. Here are a variety of presets available for symbolizing a layer. Today we'll use the Catalog: ColorBrewer.

So first we'll match the number of colours to that specified in the tool, and then we can select a colour scheme including palettes and ramps, to use - in this case Pastel1. Then click OK. and in the Symbology tab, click Classify and OK. Now adjacent features are distinctly coloured and the overall visualization is much easier to interpret.

Now lets explore graduated symbologies using the grain elevators layer. Graduated styles can be used to visualize concentrations, magnitudes or frequencies of a variable with a specific colour ramp – like vehicle collisions, earthquakkes and population sizes. The style is restricted to numeric field types. So we'll use the Capacity_Tonne field.

The Mode determines the method used to establish value ranges or “break values” used in visualization. So we can use Pretty Breaks which defaults to easily interpreted value ranges. The Precision parameter determines the number of decimal places in the Legend Values and we can alter the Classes value in the bottom right corner to change the number of value ranges used in visualization. Clicking Apply and looking in the Canvas , nearly all elevators are coloured white, with select elevators on the coasts being red. This is because there are many more primary and process elevators with smaller capacities than there are export elevators, with much larger storage.

In the Histogram tab, we can click Load Values to assess the distribution of data and value ranges, which informs the most appropriate Mode to apply. So here, given that most features are in the first value range, we'd want to apply a different mode, in this case a Quantile (Equal Count), so that an equal number of features are in each value range.

We still want to edit the Value ranges to be more intuitive, double-clicking and entering the new values which should also update the Legend values. So we'll alter to 5000 and 50000. We'll also alter the Legend values for the Upper and Lower bounds switching to greater than 50000 and less than 5000. Clicking apply and looking in the Canvas there is a much better distribuiton of colour across the features, reaffirmed back in the Histogram tab – where features are more evenly distributed across the value ranges.

For point and line geometries we can also alter the size of symbols between ranges to enhance visualization. So let's increase the size of the point symbol by 0.5 for each value range. Click Apply and OK. So as seen in the Map Canvas this offers a visualization of the differing storage capacities between individual elevators.

There are three additional symbology styles for point geometries. We can apply a Point Cluster symbology, and within the Render Settings - see our Graduated symbology style is still applied. The cluster style will provide a dynamic count of features based on the scale of the Canvas and specified Distance – determining the radius for clustering. As we can see zooming out – the counts of clustered features becomes larger and zooming in – we can begin to see individual features.

The Point Displacement symbology is effectively the same as Cluster, but depicts the individual features displayed in a particular geometry around the Cluster . Additionally features can be labelled using a specified field, here using the Capacity Tonne field. As shown, this style is not the best for detailed datasets or coarser scales, but is suitable when the features are sparser or the Canvas is at a finer scale enabling the properties and attributes of individual features to be distinguished within the Cluster.

The final style is the Heat Map, which will create a dynamic, raster style interpolation according to the spatial distribution of points. So lets switch the colour ramp to Red-Yellow-Greens and reexpand the drop-down to Invert the Colour Ramp. Additionally we can weight the visualization by a numeric field. We'll use the Capacity Tonne field as the Weight parameter – clicking Apply and OK. Zooming in and out we have a dynamic visualization of storage capacity that changes with scale. Now perhaps we want to alter the colour ramp, because in this case the green areas effectively mean zero storage capacity. Rather than expanding the drop-down click the Colour Ramp itself. Now we can edit the colour gradient relative to the value ranges or change the Transparency for only one colour by clicking on the stop and altering the Opacity slider.

Back in the Canvas we can now see the underlying boundaries along with our heat map. Finally we'll Save the Project File As, giving it a name – calling it VectorVisualization, so that we can use it in our follow up video, where we'll cover rule-based symbologies, and labelling schemes.

(Canada wordmark appears.)

Date modified: