Urban land serves multiple, often overlapping functions, which can change over time and vary between day and night, sometimes only apparent to local residents. Understanding these patterns is critical for monitoring population dynamics, particularly as tracking change over time can be complicated by inconsistent boundaries in successive Censuses. Accurately summarising population data supports a range of stakeholder applications, including planning for educational provision, allocating resources to schools, and assessing risk management needs such as emergency services, flood planning, or health interventions. By linking land use, population trends, and temporal patterns, city planners and policymakers can make informed decisions that improve service delivery, mitigate risks, and respond effectively to evolving urban demands.
This practical investigates spatial patterns of day and night-time populations in Liverpool, including variations across different age groups. It also examines how residential and employment populations are distributed across the city, using the Local Authority District as a case study. The analysis considers the clustering of different industry types and how these clusters attract workers from various parts of Liverpool.
The aim of the practical is to apply GIS to explore the socio-economic geography of the city. The analysis utilises data from Ordnance Survey (OS), the 2021 Census for residential populations, and 2011 Census data for workplace populations, enabling a detailed examination of population distribution, employment patterns, and urban spatial dynamics.
You will also be developing the following GIS skills and understanding:
Let’s start by adding data to the QGIS display. First, we add the Census 2021 population data for Liverpool Local Authority District at LSOA level
Population by right
clicking on it and selecting Rename Layer.This will add a layer containing information about Liverpool’s Census
2021 population aggregated by Lower Super Output Area (LSOA).
QGIS has a number of different ways of navigating around spatial
data.
Explore the data by using some of the navigation tools such as Zoom In, Zoom Full and Pan Map
The Identify Features tool allows you to select an LSOA on
the map and see the attribute information stored in the shapefile about
that LSOA.
Click on any LSOA, a window will appear, titled Identify Results with information about the LSOA you selected e.g. the LSOA code or total population.
When we add a shapefile, QGIS randomly assigns a colour. You already know from the GIS practicals in Year 1 how to change a layer’s colour, so take some time to experiment with different colours.
Right click on the Population layer in the
Layers Panels and choose Properties >
Symbology option . Play with different options, explore various
colours, opacity etc.
Once you’re happy with your selection, click OK and this will close the Layer Properties window and update the colour on the map.
The options you have in this layer will depend on what type of spatial data you are dealing with. The `Population’ layer is a polygon layer, so we can change the colour of the polygons and their borders. Point layers or line layers will have different options.
When working with a large number of datasets/layers it may be useful to group them in a logical way, so the Layers Panel appears less cluttered.
OS data.Now is a good time to save the QGIS project file. It is highly recommended to save your work fairly often as QGIS can occasionally crash and your work may be lost.
To visualise population patterns in Liverpool, we will use the population layer. At present, the map simply shows the LSOA boundaries, with no information on how the population is distributed across the city. To make the map more informative, it is useful to display spatial patterns such as population distribution or density at a small-area level. Drawing on the skills you developed in Year 1, you should be able to symbolise and classify the population data to reveal these patterns. As the population dataset contains numerical data, a function called Graduated is typically used, but for categorical data the Categorized function is more appropriate.
In case you’re not sure how to proceed, follow the steps below:
Population layerAt this stage, the Symbology window should be filled
in as on the picture below:
Now, we are going to change the default colour and adjust the LSOA boundaries, so the map looks more professional.
Your map should now look something like the one below:
Go back to the Properties/Symbology window
Click on the Histogram button and then Load Values
Adjust Histogram bins value to 25
What does it tell you about the population distribution, is the data normally distributed or skewed?
Can you describe spatial patterns of population distribution in
Liverpool?
Is this more likely to be a day-time or night-time distribution - why?
How different classification modes (Jenks, St Dev) change the population distribution
Lecture 2 and additional reading will help you learn more about various classification schemes
You can get a summary statistics on the population data by going to Vector > Analysis Tools > Basic Statistics for Fields
Select Population as your Input layer and Total Pop as the Field to calculate statistics on, click Run
Now, create a copy the Population layer by right
clicking on it > Duplicate Layer
Rename the new layer to Working_age
Right click on the Working_age layer then
Open Attribute Table > Field calculator and create a
new field called Work age where you calculate the total number
of those between 16 and 64 years old
In the expression window, type the following formula: “16 to 24 y” + “25 to 34 y” + “35 to 49 y” + “50 to 64 y”, click OK
A new field, showing the total number of working-age population, should be added to your Attribute Table
Save the edits (right click the layer > Toggle Editing > Save)
Then following the above steps in Section 2.2.4 to create a map
of Working_age population distribution in Liverpool (Use
Work age as your Value to classify the
data)
How does the distribution of the Work age vary from the entire residential population? Check the histogram too.
The Census 2021 residential population data pertain to the so-called night-time distribution, as during the day many people commute to their work places. The concept of the daytime population refers to the number of people, including workers, who are present in an area during normal business hours, in contrast to the residential population present during the evening and night-time hours. So let’s have a look at the day-time population in Liverpool, captured by the so-called workplace zones data. Start from loading up the relevant data:
WPZONE
layer and explore itThere is only one field called WZ11CD, which is a unique
code for UK Workplace Zones (note: these are different to LSOAs).
Importantly, there isn’t any population data attributed to the layer, so
we need to add this information. As you may remember, this can be done
by joining a numeric table to the shapefile. In order to join tabular
data, it is necessary that both of your datasets have a common attribute
(e.g. a name, unique reference or code). Can you identify the common
field for the WPZONE layer and WP102EW table?
If you open the WP102EW table you will notice that the
first field is called WZ11CD, so yes - our join will be
based on that field.
Right-click on the WPZONE layer, select
Properties and click on the Joins
option
Click on the plus button to create a new join.
The Add Vector Join dialogue box will open
Make sure that WP102EW is selected in the Join layer dropdown box
WZ11CD should be selected in the Join field dropdown box
WZ11CD should also be selected in the
Target field dropdown box (as per picture below)
Hit OK twice
Open Attribute Table of the WPZONE layer and you
will see that several new fields have been added to the Attribute table!
Please ask for help if this is not the case
So, now we should map the Workplace zones population, but there are two things that we need to do before. First, the join that we have made is not permanent, which means that it’ll be lost once you close the project/QGIS. By now you should know how to make a join/layer permanent, so go ahead and do it. In case you’re not sure, follow the steps below:
WZ_populationWZ_population newly created layer will be added
automatically to the Layers PanelSecond, we need to rename the columns in the Attribute Table as the existing ones do not make much sense. You can get the relevant column names from the table called variables_description.csv, saved in your working directory/data/Workplace Zone. The top three variables are the ones you need.
To rename the variables follow the steps below:
There are various ways of renaming variables in QGIS. A tool called Refactor fields can be used, however, in this instance we will use a different method (using Field calculator), where we will create new columns and name them appropriately. This methods also changes the type/format of the variables from text to numeric which is essential for any .csv data.
We have already used the Field Calculator; however, we will now explore some of its other functions. This tool is widely used for interrogating spatial data and performing calculations based on existing attribute values or defined functions. For example, it can be used to calculate the length, perimeter, or area of spatial features, as well as carry out a range of other operations such as creating or deleting fields. The results can be written to a new attribute field or used to update existing values.
Important
Note: text files cannot be displayed using the ‘Graduated’ scheme in
QGIS - text variables won’t be simply visible when you try to classify
the data. Please follow the steps below:
WZ population layerWZ_pop in the Output field
name box and choose Integer (64 bit) as your output
field type"WP102EW_WP" or something
similar (this may vary depending on the version of your QGIS)"WP102EW_WP"WP102EW_WP_1 column too
- name it Density (use Decimal number (real)
as your output field type, set Precision to 2, if you
can change it)Now you are ready to map the workplace zones population in Liverpool:
Create a map of WZ population by following the steps from Section 2.2.4
Use WZ_pop column to classify the data and apply
Greens as the Colour ramp
Your output map should look something like the one below:
How similar the spatial distributions of the day and night-time population in Liverpool are?
Can they be directly compared?
Also, can you think of a location of the major employers in Liverpool such as the Universities, Hospitals, Airport or major retail areas? Is there any relationship?
In order to identify the major employers in Liverpool we will use the
FunctionalSite layer from the OS dataset. We will
also explore the relationship between the major employers and day-time
population, Our basic analysis will comprise two steps. Firstly, we will
select those areas that have the highest numbers of WZ population count
- let’s say above the 5th quantile, which in our case is 658 people.
Then we will use this information to extract the Functional Sites that
are located within the selected Workplace Zones.
Open Attribute Table of the
WZ_population layer
Click on the Select features using an expression
button
In the expression window type this simple query “WZ_pop” > 658 and click Select features (note: it may not work if you do simple copy > paste)
Now, you should have all the workplace zones (WZ) with the
population above 658 selected - 86 WZ in total
To select the Functional Sites that intersect with the selected
WZ go to Vector > Research Tools > Select by
Location
Select features in Functional Site that intersect with WZ_population
Check the box Selected features only
Click Run
Check your output against the map below:
Now, save the selected functional sites as a new layer
Right click the FunctionalSite layer and export the
selected features as a new shapefile and name it
WZ_FunctionalSites (Right click FunctionalSite >
Export > Save Selected Faetures As… )
Note: If you are getting an error saying: Feature has
invalid Geometry… This can be fixed by enabling the Processing
Toolbox (right-click the top anywhere and toggle on)
> Fix geometries (type in the search box ‘Fix
geometries’).
Put WZ_population as the Input layer.
Click the (…) next to [Create temporary layer] to save to your
directory. Choose where to save the output and name it
WZ_population2.
Continue the rest of the instructions with the newly saved
(WZ_population2) shapefile.
Labels can be added to a map to show some information about an object/spatial entity. Any vector layer can have labels associated with it. These labels rely on the attribute data of a given layer for their content. In this practical, we will display labels for the WZ_FunctionalSites layer. Follow the steps below:
As we have labelled all the sites, the labels tend to overlap and as such, may not be very useful. Ideally’ we would show only those labels for the major employers such as hospitals, universities and the airport.
This can be executed by using the Rendering function within the Labels window. You need to create a simple SQL query that will select the above mentioned sites. This method gives you full control over the labels you want to display.
In Label options, scroll down to the
Data defined > Show label button
Click on it and select Edit.
In the window that opens up, write a simple SQL query that will
select the required three features
Familiarise yourself with SQL queries here: https://www.w3schools.com/sql/sql_wildcards.asp and try doing it yourself. However, if you get stuck, the following query should be helpful “distname” LIKE ‘%Hospital’ OR “distname” LIKE ‘%Airport’ OR “distname” LIKE ‘%University%’
Experiment a bit more with your labels:
One of the most useful options is to be able to move labels manually
as the default placement, offered by QGIS, may be far from ideal… The
build in option of Label Placement is very limited and it
may be very tricky to get your labels in a desired place, so the
solution is here:
WZ_FunctionalSites layer to the boundary
of Liverpool. At the moment the largest functional site:
Port of Liverpool extends well beyond the city
boundaryThen
WZ_FunctionalSites as the Input
layer and Liverpool_boundary as the
Overlay layerWZ_FSites, click
OKWZ_FunctionalSites layer >
Styles > Copy StyleWZ_FSites > Styles >
Paste Style (this step saves you time as you can simply copy
> paste all styling work you have done so far)WZ_FunctionalSites layer from the
Layers PanelOptional
You may also need to use various Census 2021 data (including workplace population) for any other research project (e.g. your dissertation) so the short instructions below demonstrate how to download Census 2021 data from the Nomis website.
Download Census 2021 data from Nomis
- Go to https://www.nomisweb.co.uk/ and click on Query Data
under Data Downloads
- You’ll see a list of all datasets available from Nomis. Select Census
2021, then for example the ‘Number of usual residents in households and
communal establishments’
- On the left-hand side click on Geography and then select 2021 super
output areas – lower layer
- From the drop-down menu select Liverpool and click on the ’tick all’
button next to it
- Check the box next to ‘Tick to select columns’ under ‘residence
Type’
- Then under ‘Format/Layout’ make sure ‘Comma separated values (.csv)’
is selected and check the box next to ‘Include area codes’ under ‘Other
options’, then hit the ‘Download Data’ button
- Once your data is ready for Download, click on the file and then open
the downloaded Excel table
- Delete rows 312 and then rows 1-7 – these are rows with additional
information that you won’t need it
- Type LSOA CD in the unnamed column and save the table to you M: drive.
Name it: Census2021-population
Now that we have set up our layers, compared the day-time vs. night-time population in Liverpool, done basic spatial analysis and looked at population change, we can start creating some maps. It is simply possible to save your maps as image files using Project > Import/Export > Export Map to Image. This is useful if you need a simple map without any key/legend. Instead, we will produce maps which include key cartographic elements, so they can be published. More specifically, in order to make maps publishable and easily interpretable there are several things you need to be aware of, such as the layout, level of generalisation, clarity of symbols, and perhaps above all, some understanding about what is the purpose of your map.
Liverpool Population as the title and click
OK, the Print Layout window will now open with a blank
pageYou should notice that the data layers that we have on display in the Print Layout are the same as that in our QGIS project (i.e. the two displays are linked). So if you need to adjust anything in Print Layout, switch windows back to the QGIS project. Ensure you have switched on only the following layers: WZ population and WZ_FSites
Go to Add Item > Add North Arrow and draw the extent of it on the map.
Alternatively select SVG Image and choose one of the SVG images of a north arrow you like
Once you have finished your map, go to Layout/Export as
image.
Specify the output type as TIFF or PNG, use 300dpi as your resolution and name the file e.g., Major Employers in Liverpool.
Your final map should look similar to the one below:
Does your map have the same extent as the one above? If not, then
go back to the main QGIS project and clip the WZ population
layer to this trimmed extent of Liverpool City Borough Council (your
Liverpool_boundary layer).
You have now completed the Practical 1 exercise. Well done!!!