Skip to main content

How high is your Charity?

The question from @kanedr was:

Anyone know if there's an easy way of finding the altitude for a postcode? I want to find Britain's Highest Charity.

Which is just the kind of question we like to distract us from doing proper work.

A quick bit of searching shows that you can use the Google maps API to get an elevation for a location - but the restrictions on the number of requests and the use of the data meant that wasn't going to cut it for us.

There are a couple of data sets containing elevation data that we could find. The most exciting one is NASA's SRMT database which was generated by the Space Shuttle Endeavour. In the end though we plumped for the Land Form Panorama dataset from OS OpenData.

Whilst we were on the OS OpenData site we also got the Code-Point® Open dataset to provide us with postcode to grid reference data.

Last but not least we needed a dataset for charity postcodes - and since @kanedr is David from the NCVO Almanac then we thought he counldn't object if we used the data from

Having got all our data sets we then needed to sort them out. The first step was to get the postcode data from the Code Point csv files into a mysql database along with the charity postcode data from the Almanac.

Then we had to work out how to extract the elevation data we needed from the NTF files. Thankfully we found this very useful page which provided some very nicely presented code to translate the grid references to elevation.

After that it was just a case of writing some PHP scripts to chug away and look up values for all of our charity postcodes whilst we sat back and had a cup of tea.

And the winner is...

Really I should do a teasing reveal here, but I know you just want to see the data, so the top 20 charities in height order are:

Quarnford Village Hall463 m
Alston Goods Shed Trust453 m
Upper Weardale Festival of Music447 m
The Allenheads Centre for the Arts and the Environment440 m
Nenthead Village Hall440 m
Hunstanworth Village Hall432 m
Princetown Preschool and Playgroup421 m
Storybook Dads420 m
Princetown Community Centre419 m
Walkhampton Pre-School415 m
The Parachute Regimental Association South Devon Branch412 m
The Tavistock Physically Challenged Group409 m
Two Moors Festival Limited399 m
The Henry Leigh Withypool Educational Trust397 m
Horeb Baptist Church (Manse Held in Connection With)394 m
Garn-Yr-Erw Welfare Association391 m
Parson House Outdoor Pursuits Centre391 m
Ebbw Vale Street Pastors390 m
Lighthouse Ministries390 m
Bettws-Y-Crwyn Village Hall390 m

So congratulations to Quarnford Village Hall and commiserations to Alston Goods Shed Trust - better luck next year.

There are a few caveats in that we don't have postcode data for all of the charities and some of the elevation data is reportedly patchy but hopefully we've got the winner right at least.

Now we have the data we'll try and get it up online soon in case anyone can think of anything useful to do with it. Send us a Tweet if you're interested.


Saturday, 12 July 2014

by Stephen