Skip to content

Sample project

Urban Heatmap Data Analysis

Turning a scattered point dataset into a normalised density surface that separates real activity clusters from population artefacts.

Study area
One metro area, 1,240 km²
Input records
48,600 raw points
Aggregation
500 m hexagonal bins
Method
KDE + Getis-Ord Gi*
Duration
3 weeks
Input records
48,600

Cleaned, re-geocoded and quality-flagged

Records corrected
9.1%

Centroid fallbacks and coordinate mismatches

Hotspots confirmed
2 of 5

Survived bandwidth sensitivity testing

End to end
3 weeks

From raw file to delivered map pack

Problem

What needed answering

A planning team had a large point dataset covering a whole metro area and a map that showed one enormous blob over the city centre. Every version of the map said the same unhelpful thing: the middle of the city is busy.

The underlying question was different. They needed to know which districts had unusually high activity relative to how many people lived there, and whether those concentrations were statistically real or just the visual result of a generous smoothing radius.

The raw dataset also could not be trusted as it stood. Roughly one record in eleven had coordinates that disagreed with its stated address, and several thousand shared an identical coordinate because they had fallen back to a postcode centroid during an earlier geocoding run.

Data sources

What went in

  • Point activity records

    48,600 records with addresses and partial coordinates, supplied by the client.

  • Population grid

    Small-area population counts from the national statistical agency, used as the denominator.

  • Administrative boundaries

    District polygons for reporting, cleaned so they tile without gaps or overlaps.

  • Road network

    Open mapping data, used to check that dense cells corresponded to accessible places.

Method

How it was done

Every record was re-geocoded and given a match-quality flag. Records that had silently fallen back to a postcode or district centroid were identified by their duplicated coordinates and excluded from the density surface, though they were retained in the district-level counts.

Points were projected into an equal-area coordinate system before any distance or area calculation. Running density in degrees is one of the most common ways a heatmap ends up quietly wrong, particularly at higher latitudes.

Kernel density estimation was run at four bandwidths, from 200 m to 1,000 m. Two of the five apparent hotspots survived at every bandwidth; the others merged and dissolved depending on the radius, which is exactly the evidence a decision-maker needs to see before trusting them.

The surface was then normalised by residential population and by daytime population separately. The two normalisations disagreed in a way that turned out to be the most useful finding in the project.

Finally, Getis-Ord Gi* was computed on the hexagonal aggregation so each cluster carried a confidence level instead of only a colour.

Processing

The pipeline

Each stage produced an artefact that the next stage consumed, so any result can be traced back to the input that created it.

  1. 01

    Raw data

    CSV

    48,600 supplied records with inconsistent address formatting, mixed coordinate precision and no match-quality information.

  2. 02

    Data processing

    PostGIS

    Address parsing, re-geocoding with match quality recorded, duplicate and centroid-fallback detection, projection into an equal-area CRS.

  3. 03

    Spatial aggregation

    Hexbin layer

    Cleaned points binned into 500 m hexagons, joined to population and district geographies for normalisation and reporting.

  4. 04

    Heatmap

    GeoTIFF

    Kernel density estimation at four bandwidths, normalised by residential and daytime population, with sensitivity compared across parameters.

  5. 05

    Final visualization

    Web map + PDF

    An interactive map with bandwidth and normalisation toggles, plus a print map pack and a written method note.

Visualization

The output

Final surface · 400 m bandwidth · normalised per residentLowHigh

Data

Results table

Sample project · District results after normalisation
DistrictPointsPer km²Per 10k residentsGi* z-scoreConfidence
Central12,840184.216.47.8299%
Harbourside6,41096.828.96.1499%
University5,980112.424.15.0299%
Northgate4,22048.19.81.11Not significant
Eastbank2,18021.64.2-3.2895% cold

Findings

The key comparison

  • Centrallargest raw count16.4
  • Harboursidetrue hotspot28.9
  • Universitydaytime driven24.1
  • Northgate9.8
  • Eastbank4.2
Activity per 10,000 residents. The district with the highest raw count ranks third once population is accounted for.

Result

What the analysis showed

  • Central had by far the largest raw count and by far the largest visual hotspot, but ranked third on activity per resident. The original map had been describing population distribution, not activity.

  • Harbourside, which barely registered on the unnormalised map, was the strongest genuine hotspot at 99% confidence. It has a small residential population and a high concentration of activity, precisely the pattern raw-count heatmaps hide.

  • University showed the largest gap between residential and daytime normalisation, confirming that its activity is driven by people who travel in rather than people who live there. That distinction changed which intervention the team proposed.

  • Two of the five apparent hotspots on the original map did not survive bandwidth sensitivity testing and were dropped from the final recommendation.

Deliverables

What was handed over

  • Cleaned and geocoded point dataset with match-quality flags per record
  • 500 m hexagonal aggregation layer as GeoPackage and GeoJSON
  • Kernel density rasters at four bandwidths, both normalisations, as GeoTIFF
  • Getis-Ord Gi* results with z-scores and confidence levels per cell and per district
  • Interactive web map with bandwidth and normalisation toggles
  • Print map pack as PDF plus a method note covering parameters and limitations

Next step

Want something similar for your market?

Tell us the geography, the category and the decision. We will scope the equivalent project and send a fixed price before any work starts.