I've had a request recently to generate a map which includes UK Postcode districts, ie aggregations of postcodes based on the first section of the code (NW2, B1, E11 etc.).

From what I've read, these aren't available freely ([Postcode Shape Files for the UK](https://gis.stackexchange.com/questions/32321/postcode-shape-files-for-the-uk)).

Is there a way of scripting aggregation of boundaries in either QGIS (or possibly R)? I've done this sort of aggregation before using MapBasic but no longer use MapInfo (plus it gave really messy boundaries).

I'm thinking I may use Voronoi regions rather than the actual postcode boundaries as this will be easier in terms of file handling (my postcode shapefiles are split across lots of files so easier just to run Voronoi on the OS Codepoint data set, plus I imagine this will give cleaner, if less accurate, boundaries)