Linked to my previous post, here’s another example of the power and potential of blending multiple open data sources about specific localities. This one is inspired by Alasdair Rae’s interesting blog post on mapping spatial patterns of deprivation. Following Alasdair’s example, I have:
- Downloaded the relevant slice of Ordnance Survey’s VectorMap District dataset.
- Used Quantum GIS to extract buildings falling within the Leeds City Council Boundary (using the boundaries from Ordnance Survey’s BoundaryLine open data product).
- Again using Quantum GIS, flagged individual buildings with the associated Lower Super Output Area codes. I obtained these codes from the 2001 LSOA boundary files downloadable from ONS’s Geoportal.
- Used OpenDataCommunities to extract the 2010 overall Index of Deprivation rankings for all Lower Super Output Areas in Leeds. See example query below.
- Used QuantumGIS to join the IMD ranks (from OpenDataCommunities) to the buildings in Leeds.
- Created a shapefile which assigns IMD ranks in 10 per-cent bands, from most to least-deprived
- Published the shapefile to this Geoserver, so the data are available for re-use via its Web Mapping Service.
Using OpenDataCommunities to query IMD ranks
This requires a little bit of knowledge of LinkedData and the SPARQL query language. Here’s the query I wrote to get the area codes, names and 2010 overall rankings for all LSOAs in the Leeds City Council area.
select ?lsoacode ?lsoaname ?imdrank where { ?s <http://purl.org/linked-data/cube#dataSet> <http://opendatacommunities.org/data/societal-wellbeing/deprivation/imd-rank-2010> . ?s <http://opendatacommunities.org/def/ontology/societal-wellbeing/deprivation/imdRank> ?imdrank . ?s <http://opendatacommunities.org/def/ontology/geography/refArea> ?refArea . ?refArea <http://www.w3.org/2004/02/skos/core#notation> ?lsoacode . ?refArea <http://www.w3.org/2000/01/rdf-schema#label> ?lsoaname . ?refArea <http://data.ordnancesurvey.co.uk/ontology/admingeo/inDistrict> ?lauri . ?lauri <http://data.ordnancesurvey.co.uk/ontology/admingeo/gssCode> "E08000035" . } ORDER BY ?lsoacode
You can run this for yourself by copying and pasting the query here – http://opendatacommunities.org/sparql. Note too that you can get IMD rankings for different local authorities by simply changing the area code for Leeds (“E08000035”) to the area of your choice.