This repository contains code to generate geographical trip-points for each 2011 Lower Layer Super Output Area (LSOA11) in Wales, and some LSOA11s in bordering areas in England, for transport-related analysis.
You can find the latest release of these trip-points here.
It attempts to address the problem that for some LSOAs, particularly rural ones, the population-weighted centroid might be in the middle of nowhere - far away from any actual place, public transport stop or road. Trip planners may not be able to find routes to and from these centroids.
These “trip-points” are generated in a two-step process:
For roughly the third of the included LSOAs with the greatest areas, I find the village, town, bus stop, train station or pub nearest to the population-weighted centroid.
For each LSOA, I find the nearest motor-vehicle accessible road to a) the place found in the first step for the 850 or so biggest LSOAs or b) the population-weighted centroid for the 1750 or so remaining LSOAs.
The first step attempts to find points where it might actually be possible to start a public transport journey, while the second step all but guarantees that it will be possible to start a car-based journey.
Many existing analytical products are only available at LSOA-level or higher, for example Car and van availability from the 2011 Census and different countries' Indices of Deprivation.
LSOAs are a relatively manageable number of data points (1909 LSOAs in Wales) resulting in relatively manageable travel-time matrices (around 3.6 million cells in Wales, around 12MiB in a CSV), in contrast to Output Areas (ten thousand OAs resulting in 100 million cells in a travel time matrix).
Rural LSOAs can have very large geographical areas containing multiple scattered settlements; a single trip-point for such an area may be extremely unrepresentative, and accessibility - particularly for public transport - determined based on such a point may be quite misleading.
Some routers (including OpenTripPlanner) may have issues navigating from roads that don't have access restrictions themselves but are accessible only via roads that do.
Not all bus stops and railway stations are mapped in OpenStreetMap. In particular, many of the former are missing from rural parts of Wales. This may lead to suboptimal place selection in the first step. (An alternative might be to use the NaPTAN database.)
devtools::load_all()
download_lsoa_data()
decide_lsoas()
download_osm()
extract_osm()
decide_place_points()
decide_nearest_road_points()
create_not_included_mask()