Update to CityDashboard CSV API & iPad Wall!

I’ve made some minor alterations to the CSV API for CityDashboard. The main changes are in the metadata rows (the top two) rather than the subsequent rows. Specifically, the top metadata row has now split out the description, source and source URL – which were previously rather messily combined into a bit of HTML – into three text fields; and the second metadata row now uses properly formatted names for value titles, i.e. including spaces, and units, for example “broken_pc” now becomes “% docks/bikes broken”.

The reason for these changes is to accommodate a new and exciting use of the API here at CASA – our lab hardware specialist has recently been hard at work building an “iPad wall” and one of the visualisations in it is of CityDashboard data. Here’s what the uncompleted – but operational – iPad wall looks like (source):

It’s a physical CityDashboard!

I also took the opportunity to fix a few bugs and typos – mainly just cosmetic, but including a pretty silly one for the Mappiness-sourced data that was over-reporting the true value by a large and variable amount. Entirely my fault. That will serve me right for doing a coding change during a colleague’s Ph.D viva drinks reception! I also handle temporarily unavailable source feeds a little better – they’ll now appear unavailable for one complete update cycle but it means the source server doesn’t get repeatedly hammered until it comes back up again.

Velo-City Preview

[Updated] I’ll be presenting at Velo-City in Vancouver later this week. Velo-City is the “world’s premier cycling planning conference”. It is likely to have a significant bike-sharing flavour – the lead sponsor being PBSC which designed the 6000-odd “Boris Bikes” (aka Barclays Cycle Hire bikes) that are a distinctive sight in central London, as well as equivalent systems in Montreal, Washington DC, Minneapolis, Boston and (shortly) New York City – known generically as Bixi bikes. Vancouver does not have a bike-sharing system of its own, but PBSC have imported a whole load of their Montreal bikes for delegates to borrow for the week, although a recent collar-bone break means I unfortunately won’t be taking up the offer. I did however spot a PBSC/Bixi bike “in the wild” in Vancouver’s beautiful Stanley Park – see above.

I’ll be talking about some new insights into bike-sharing cities worldwide that have been revealed by my Bike Share Map, as part of a three-part presentation on looking at bike-sharing cities at different scales – my co-presenters being the author of the Bike Sharing World Map, and the software developer behind the B-Cycle bike sharing systems.

My presentation is on Wednesday morning (Pacific time) and I’ll write/tweet about it on the day, wifi-access permitting.

To prepare for the presentation, I’ve added a few new cities to the Bike Share Map: Suzhou, Zhongshan, Wujiang, Shaoxing and Heihe in China; and Kanazawa in Japan. One early insight coming from these new maps could be that the Chinese really do work hard (if you excuse the gross overgeneralisation) – typically 11 hours between morning and evening commuter peaks, and seven days a week!

Hehei is shown below – it’s right on the Russian border, opposite a much larger Russian city – hence the Cyrillic (although no bridges across the river near there!)

Note that, in the maps of the Chinese systems, the docking station locations are slightly misaligned with the background maps because of location obfuscation carried out by that country – I’m using OpenLayers rather than the Chinese-based map service that corrects for the errors. The resulting offset is typically only 1-400m though so you can still get a good idea of the shape and size of each system.

Mappiness – A Personal Mood Map

The Mappiness project is run by one of CASA’s technology superstars Dr George MacKerron – it was his Ph.D project at LSE. The project, which is still going, aims to quantify happiness based on environmental factors, such as location, views and sound, as well as who people are with and what they are doing. Data is collected by volunteers downloading an iPhone app, which then pings them at random moments twice a day between 8am and 11pm (configurable) to ask them the questions and collect the data. Volunteer incentive is driven by having access to a personal webpage which contains all their collected data, visualised in a wealth of attractive graphs and maps.

I’ve been using the app since late October, it has been steadily pinging me twice a day since then, and most of the time I hear the familiar ‘ding ding’ and get around to recording the information. With around 160 responses, some interesting insights are now appearing, some(!) of which are non-personal enough to share here. The map above shows the locations where I was pinged, for the London area – yellow stars indicate where a photo was taken.

Here’s one, based on the general environment:

Perhaps more interesting is that I spend much less time outdoors than I thought. The app (by default) only asks for a picture if you are outdoors, so by counting the number of pictures that appear on my personal webpage – just 14 out of 161 – this in theory means that I spend only 8-9% of my waking life outside. This percentage will hopefully grow as summer approaches and things start to warm up again.

Because I don’t get to choose when to post the images, the photos are a good snapshot of my “everyday” outdoor view, rather than a nice or interesting place that I would specifically stop to photograph. Here’s a couple of my most recent ones:

One of Dr MacKerron’s current projects involves using Microsoft Kinect sensors for visualisation – this is my very tenuous link to allow me to post the image below, which is a 3D grid “photograph” of me at my desk, constructed from Kinect data.

Mappiness managed to choose to ping me this morning precisely at the moment that my bike chain snapped, on the way to work. Needless to say, a low score for happiness was recorded.

Map background Copyright Google.

Vienna: Previewing GEMMA

At State of the Map EU I presented a preview of GEMMA, my current UCL CASA funded project, focusing particularly on the OpenStreetMap Feature Highlighter, that will be one of our key data sources – it being an OpenStreetMap conference, I thought this would be of most interest to the audience. GEMMA is more than that though – it will both be a portal of content and created maps, and a mobile application for collection and viewing of data.

Unfortunately my talk clashed with a cartography talk but quite a few people were in my track and saw some screenshots of OpenStreetMap data being highlighted in GEMMA. I also talked about integration with other CASA data sources – GEMMA is a consolidation project to tie together a number of CASA products – and mocked up some examples, focusing on a need to understand more of the demographics of London bike-share cyclists, a current personal interest of mine.

GEMMA is a JISC-funded project that I am working on with Steven Gray. It’s one of the JISCGeo projects, and should launch this autumn. It has its own website and also a blog, where I go into more detail about the project. This is the first CASA project, I believe, to make significant use of OpenStreetMap, and its great that we are now able to take advantage of such a rich and expanding dataset.

The iPhone Locations DB – Fun, but not Accurate

As a followup to my previous post about the (re-)discovery of the iPhone locations cache, the graphic above shows the apparent locations (of known mobile-phone masts and wifi) that were captured on my iPhone, over the last couple of weeks while I have been in Scotland. These were either independently detected by my iPhone and georeferenced using a built-in service, or, more likely as it turns out, the details of supposed nearby masts were downloaded by my iPhone from this service, based on its own location, in the hope they would subsequently be detected and allow for quick positioning.

The graphic is from my hacked version of iPhoneLocator, changed to show a higher density of dots and include the wifi data. I have superimposed on the map red lines showing where I’ve actually gone over the break. Some of the detected (or downloaded in the hope of detection) mobile-phone masts were over 40 miles away from where I actually was. Some of these may have been when I was on top of a Munro (i.e. over 3000 feet up) which therefore affords a good line of sight. Or simply, there were so few in the area, that details from the far-away ones were the best available to be obtained.

If I hadn’t drawn the red lines, you would probably be surprised to discover, for example, that I never went to Inverness during this trip (the big patch of yellow circles in the very top part of the map extract. I also never went along the various roads visible in the north, west or east part of the map, but my phone still saw the towers in these locations. So to conclude, take the detected locations with a pinch of salt. They tell you where an external database thinks a cell-phone tower once was, or where the nearest few are, even if they are a long way away. They certainly don’t tell you where you’ve actually been…

Should the UK move to Double Summer Time?

Every autumn, as predictably as the clocks going back from British Summer Time (BST, i.e. GMT+1) to Greenwich Mean Time (GMT), there are newspaper articles with people suggesting that we scrap the change and just stay with BST all year around. Lighter evenings in the winter would make days feel longer for most people, and reduce the gloom of the season. Indeed this was done, for a few years from 1968, but politics intervened and we went back to the the annual GMT/BST cycle. Well, things might be changing. More specifically, we could be moving to the timezone that much of the rest of Europe adopts – GMT+1 in the winter, GMT+2 in the summer (so Double Summer Time is a bit of a mis-nomer.

What do you think? Here’s a 10-second survey:

Where is London?

When I was at school, I lived a long way up north. My geography of the much of the rest of the U.K. was limited to the AA road atlas my parents had in the car, which I used to look at compulsively during long journeys. I was fascinated by the schematic diagrams showing the layout of road junctions on each of the motorways. The motorways were represented on the diagrams themselves by dead straight lines – with one exception: the M25. This motorway was shown as a square, apparently enclosing all of London. So, for many years, I assumed that the London boundary was the M25 itself. I was a little disappointed when I moved down to the city and discovered this was not the case. Several large areas – Epsom, Loughton, Watford – are comfortably inside the M25 ring but not within the administrative boundary of Greater London. Similarly, the boundary pushes out beyond the M25 in a few, generally rural, places.

It turns out there are a lot of official and unofficial ways to define London’s extent.

  • Greater London – the administrative extent, made up of the 32 London boroughs and the City of London at its centre. It is the area that is administered by the boroughs and also forms the area of the six concentric Transport for London travelcard zones – although there are some “special” additional zones which go beyond the boundary. Greater London is shown above.
  • Greater London Urban Area – the Office of National Statistics defines this as the conurbation area of London (i.e. the continuous urban environment) which is roughly equivalent to Greater London but excludes the large rural areas within the latter boundary, such as Biggin Hill, and includes some towns which “spill over” the Greater London boundary, such as Staines and Dartford.
  • London Travel to Work Area (TTWA) – Travel to Work Areas are contiguous regions containing mainly people that both live and work there. London is such a region, its TTWA extends slightly beyond Greater London to include places with sufficiently good transport links that, as far as employment is concerned, are “local”.
  • The extent of the “020″ telephone number prefix – the dialling code for “London”.
    The London postal district – the extent of the SW, W, NW, N, E and SE postcodes. These miss out a surprisingly large part of the London urban area, except in the north, where they even extend beyond the Greater London boundary.
  • The County of London – this approximately represented inner London and ceased to exist in 1965 with the creation of Greater London. However many older people continue to refer to the counties that were lost or redrawn to accommodate Greater London, such as Middlesex, which is now subsumed by the northern part of Greater London.
  • The City of London – this still exists but only covers the Square Mile – the financial and historic centre of London. It is surrounded by the 32 London boroughs. One of the other boroughs – Westminster – is also a city. Hence the electoral constituency which currently covers both being called “Cities of London and Westminster”.

Personally, I still prefer the M25 as the boundary. If I’m heading on a long cycle ride from the centre of London to (say) Brighton, then its when I pass underneath the M25 – a very tangible, physical feature – that I feel I have finally left the city. None of the other borders described above are represented on the ground, other than by road signs. But you can’t miss a huge 6+ lane orbital highway.

The bottom set of pictures are, clockwise from the top right: The London postal district in red, the London Travel To Work Area in dark blue, the former County of London in green, the City of London in bright red, aerial imagery of London’s built up areas, and the London 020 dialling code area in red. Apart from the top picture, which is from OpenStreetMap, all pictures are sourced from Wikipedia. All the picture here are are subject to Creative Commons copyrights of their respective authors. The middle picture shows Greater London, with the boroughs (and the City of London) numbered.

Skyscraper City or Cathedral City?

Cross-posted from the Hodder Geography Nest blog, where I am one of this month’s guest-bloggers.


 

I was walking down Bishopsgate in the City of London yesterday, and I noticed the giant concrete “core” of the Pinnacle, the City’s next skyscraper, has finally started to rise out of the ground. It’s just one of a number of very tall buildings now under construction in London, after a couple of quiet years due to the economic conditions. The Pinnacle, also known as the Bishopsgate Tower and nicknamed the Helter-Skelter because of its spiral shape, will be 288m tall and is due to be completed by the end of 2012.

Next door, the Leadenhall Building is due to commence construction in early 2011, it will be 225m high and also has a nickname, the Cheese Grater. Just up the road is the Heron Tower, 230m high and was completed in July, it opens early next year. Not far away is 20 Fenchurch Street, nicknamed the Walkie Talkie because of its bulging design, which is due to start construction any day now and will be 160m high. Finally, just across London Bridge, is the Shard, which will be the tallest of all – the main core has already risen 60 stories high, and the building will be 310m high when complete, again in 2012, making it the tallest building in the European Union. A photograph of the Shard under construction is on the right.

Many of these new skyscrapers will have public viewing galleries and rooftop restaurants, so for those without a fear of heights, it is going to be an exciting few years.

An artist’s impression of the Pinnable is on the left. Three of the four buildings on the right of the picture have now been demolished – 30 St Mary Axe, popularly known as the Gherkin, remains, but the two square buildings will soon instead be replaced with the Cheese Grater and the Walkie Talkie. The building at the front has also been demolished and replaced with a new mid-level office building.

It’s anything but straightforward to build a skyscraper in London though. The planning process takes many years, and many organisations voice objections at the public enquiries, notably English Heritage, which manages the historic built environment of the country. The costs of building a skyscraper are of course very high, and there is always the risk that the demand for office space has dropped by the time the building is finally completed, as happened with the Broadgate Tower last year.

There is one other factor that is special to London – St Paul’s Cathedral, or specifically, viewing corridors to it. There are ten designated places in London, from which the view to the cathedral must be uninterrupted. Some of the places include Primrose Hill, Greenwich Park, Parliament Hill on Hampstead Heath, Alexandra Palace and most interestingly King Henry VIII’s Mound in Richmond Park. The latter view is through a small hole cut in the hedge on the mound, allowing a suprising glimpse of the cathedral standing nearly 10 miles away.

One very different kind of building development that opened last fortnight was One New Change, a shopping mall and offices on Cheapside, directly east from the cathedral. It is just 40m high, despite having as much floor space as the 225m Leadenhall Building. The building height was very deliberately fixed, so that the building appears to “nestle” alongside St Paul’s rather than overshadowing it.

The new City skyscrapers are all clustered together in the eastern part of the Square Mile, where they don’t impact on the St Paul’s protected views – by not blocking the building, appearing to be close by it from the viewpoints, or adding a dominating backdrop. Indeed, one of the reasons why the Cheese Grater building slopes back is to minimise its impact on the skyline with respect to the cathedral. No super-tall skyscrapers will be appearing immediately beside the cathedral, or to its north or west, any time soon.

The map below shows some of the protected views to St Paul’s Cathedral – marked with the red pin. King Henry VIII’s Mound is marked with the green pin.

The image of the Shard under construction is CC-By-SA George Rex photography on Flickr. The artists impression of the Pinnacle is CC-By-SA Will Fox on Wikipedia. The OpenStreetMap screenshot is of data which is CC-By-SA OpenStreetMap contributors. The photo of St Paul’s Cathedral with the pre-2007 skyscrapers is by the author.

General Election Swings Visualisation

I’ve created a visualisation of the results from the UK general election this month. By default, it shows the most significant swings between parties, for each constituency. By using the options on the right, you can change it to show simple vote counts, overall results, or swings between any two significant parties. I’m using a circle to represent each constituency. The area of the circle is directly proportional to the metric being shown (number of votes, or percentage point swing) with a dynamic key on the right to help out. Click on a circle to see the vote results.

Some Notes:

By choosing “Winning Party” from the “Other” drop down, you see the simplest map – each circle is the same size, and it simply shows the winning results – with the previous winner shown as the colour on the edge of the circle. I think this kind of view is a “best of both worlds” approach – as long as the circles don’t overlap, it has the “fairness” of cartograms (aka “proportional” maps in the BBC’s coverage) while retaining the geographical familiarity of the choropleth (“normal”) map of the UK.

Only Great Britain is included, not Northern Ireland, as the OS Open Data release, which provides the parliamentary boundaries from which the centroids were calculated for the circle locations, does not at the moment include Northern Ireland.

The definition of swing is tricky – swing can only be described as being from one party to another. Choosing which two parties to use for the “headline” swing was tricky. In the end, I’ve chosen to show the swing between the losing and winning party where the seat changed hands, and where it didn’t, the swing between the two parties with the highest number of votes. This means “interesting” swings like in Bethnal Green & Bow are still included. It does however mean that the largest swing is not necessarily shown.

There were a large number of parties contesting seats – in the end I’ve only included parties that got at least 30,000 votes in total, to prevent the lists becoming too long. I’ve also excluded swings where either party in the swing had less than 5% of the vote (i.e. losing their deposit) as such a swing is probably not very meaningful.

In general, a swing between a “small” party and a “large” party is not meaningful anyway, because any voting changes that a large party suffers/gains from are probably to/from another large party, rather than to/from the small party. So, bear this in mind when viewing the swings between (for example) Labour and UKIP. UKIP appears to have gained almost everywhere but actually it was probably another “large” party (Conservatives or Liberal Democrats) that actually got the floating votes.

The background imagery was custom-rendered to show the constituency boundaries and be entirely grey – so that the only colours are those representing the party results. Because the boundaries generally run to the low-water mark and estuary mid-lines, whereas OpenStreetMap boundaries generally run to the high-water mark and consider estuaries to be sea rather than river, there are some odd looking estuarine areas (e.g. the Bristol Channel and the Thames Estuary.)

Said another way, this is because of a mismatch between where OpenStreetMap and the parliamentary boundaries commission consider the rivers to stop and the coast to start. I have manually edited two boundaries – NW Bristol sticks far out into the Bristol Channel, and the Medway boundaries also stick far out. NW Bristol’s centroid was also manually moved. There are other, lesser quirks with the data, and being OSM data, not every village is on there yet. I consider the background imagery overall to be “good enough” for the visualisation at hand.

No fancy AJAX was used – the data (about 120KB) is simply loaded into the browser at the start – the visualisation being done entirely on your browser using the OpenLayers API.

It’s not very easy to draw circles in Javascript, so I’ve let OpenLayers do it for me. The two circles that make up the key are actually miniature OpenLayers maps themselves, with a single point feature at the origin of the map. They update in sync with the main map.

The visualisation was ready to go last week but the way Internet Explorer draws the vector graphics (using VML rather than SVG) was causing considerable performance problems, when trying to show all 650-odd constituencies at once. As a work around, the map starts by being zoomed in if you visit the site in IE. Zoom out at your peril!

If you spot any bugs (apart from the IE chronic slowness!) please let me know.