Posts Tagged ‘visualisation’

The Changing Map Of Europe’s Boundaries

The boundaries of Europe’s constituent countries have changed a lot in my lifetime. Some countries don’t exist anymore whilst others have come into existence. But it takes a map visualisation to make you realise just how much the map of Europe has changed.

Actually, it takes two map visualisations. The first, courtesy of the BBC, dates from 2005 and covers the years between 1900 and 1994. Starting wit Imperial Europe and fast forwarding though two world wars, plus the Cold War and taking in the collapse of the Communist Bloc and the expansion of the European Union.

BBC Map

The other map takes a much wider view, ranging from 1000 AD to the present day. It’s oddly fascinating to watch the Holy Roman and Byzantine Empires go from dominance to vanishing entirely.

LiveLeak Map

But the purist in me finds as much to dislike as to like in both of these maps. The BBC one is just two small and cries out for the ability to pan and zoom the map. For some unexplained reason, the map is … tiny and, though I hesitate to use the word in this content, the cartographer has obviously been experimenting with differing shades of colour to try and clearly delineate the countries but didn’t experiment hard enough.

The LiveLeak map is also small and while the video containing the map can be enlarged to full screen, there’s a loss of crispness to the map. For a map with such a wide timespan, it would have helped massively to have some kind of timeline accompanying the animation, so you can see just where in history you are.

Two maps. Both interesting. Both, for me, ultimately flawed. This sort of map just cries out to be reworked. If only I could find a suitable boundary data set spanning over a thousand years.

Written and posted from BA Galleries First Lounge, Heathrow Terminal 5 (51.47017, -0.48711)

Are You A Map Maker, A Map Builder, A Map Scripter Or A Map Creator?

These days there’s so many ways that you can make a map. You can use a Javascript Maps API and put push pins on a slippy map. You can take vector data, transform it into JSON and use a different Javascript API to make an SVG map. You can load data from pretty much any source into either a desktop GIS or a visualisation tool. The possibilities are endless; maybe more endless than you might first assume.

Thierry Gregorius has helpfully put together a cut out and keep guide to which type of mapper you are.

Map Maker Types

There’s no one size fits all classification here; I’m probably type 4 (The GMT Map Maker), type 5 (The D3 Map Maker) and type 9 (The Native Map Maker) in pretty much equal measures, verging into type 3 (The R Map Maker) and with delusions of being slightly type 1 (The GIS Map Maker). Which types are you?

Photo Credits: Thierry Gregorius on Flickr.
Written and posted from home (51.427051, -0.333344)

The Great British Map; Or Great Britain vs. The United Kingdom vs. The British Isles

Last night I made another map. It tries to answer some of more perplexing and confusing facets of the geography surrounding the world’s 9th largest island. I mean of course Great Britain. No, wait. I mean the United Kingdom. No, wait. I mean Britain. Or do I mean England? See, it’s confusing.

  • So if the ISO 3166-2 code is GBR, how come the country is called the United Kingdom?
  • But if England is a country and the United Kingdom is a country, how come England is part of the United Kingdom?
  • What about Scotland, Wales and Northern Ireland?

This isn’t the first time I’ve covered this topic. The first time was for a post on the now defunct Yahoo! Geo Technologies blog entitled UK Addressing, The Non Golden Rules Of Geo Or Help! My Country Doesn’t Exist. The ygeoblog.com domain is now long gone and redirects to the Yahoo! corporate blog but I was able to reproduce this post here and it’s also captured in the Internet Archive’s WayBackMachine. The second time was when I made a variation of The Great British Venn Diagram. But this is the first time (though probably not the last) that I’ve used a map, which is odd as this is something that’s tailor-made for a map.

I’d been looking for a good source of geographic vector data that I could use to easily overlay polygons on a map and came across a rich source of free vector and raster map data from Natural Earth. But instead of overlaying that data on top of a standard slippy map using a JavaScript maps API to tap into a tile server’s bitmap tiles, I soon wondered whether I could actually make a map from the vector data. It turned out I could and decided to revisit the structure of the group of islands I live on one more time and try to visualise the difference between Great Britain, the United Kingdom and the British Isles. The end result, punningly entitled the Great British Map, looks something like this …

Great British Map

When the page first loads you’ll see the coastlines of Britain, Ireland and towards the bottom, the Channel Islands. There’s then five ways of looking at this particular map.

There’s the group of geographic islands that’s termed the British Isles; these show up in purplish-grey and if you’re observant, the Channel Islands vanish as they’re not part of this island group.

Great British Map - Great Britain

Then there’s the individual geographic islands of Great Britain, Ireland, the Isle Of Man and The Channel Islands; these show up in green.

Great British Map - United Kingdom

There’s two sovereign states, The United Kingdom of Great Britain And Northern Island and the Republic Of Ireland; these show up in red.

Great British Map - England

Next comes the administrative countries which make up the United Kingdom; England, Scotland, Wales and Northern Ireland. These show up in yellow.

Great British Map - Crown Dependencies

Finally, there’s the Crown Dependencies, the self governing possessions of the British Crown; the Isle of Man and the Channel Islands are these and they show up as purple.

What’s missing from the map? The British Overseas Territories, which is a polite way of saying what’s left of the British Empire that didn’t gain independence and which the United Kingdom still asserts sovereignty over. These are Anguilla, Bermuda, British Antarctic Territory, British Indian Ocean Territory, British Virgin Islands, Cayman Islands, Falkland Islands, Gibraltar, Montserrat, Pitcairn Islands, St. Helena, Ascension Island, Tristan da Cunha, the Sovereign Base Areas of Akrotiri and Dhekalia and the Turks and Caicos Islands.

If you’re interested in how I actually made the map, read on.

The source data from the map are two public domain datasets from Natural Earth; the 1:10m map Admin 0 Subunits dataset and the 1:10m Populated Places dataset. This data includes shapefiles which can be converted into GeoJSON format by the GDAL ogr2ogr command line tool. I extracted the vectors for the UK, Ireland, Isle of Man and Channel Islands from the Admin 0 Subunits dataset, keying on their ISO 3166-1 Alpha-3 country codes.

$ ogr2ogr -f GeoJSON -where "adm0_a3 IN ('GBR','IRL','IMN','GGY','JEY','GBA')" subunits.json ne_10m_admin_0_map_subunits/ne_10m_admin_0_map_subunits.shp

I then extracted the place data from the Populated Places dataset, again extracting data for the UK, Ireland, Isle of Man and Channel Islands, this time keying on their ISO 3166-1 Alpha-2 country codes. Not entirely sure why one dataset uses Alpha-2 and the other uses Alpha-3 but go figure; the data is free, accurate and open so who am I to complain?

$ ogr2ogr -f GeoJSON -where "iso_a2 IN ('GB','IM','JE','GG') AND SCALERANK < 8" places.json ne_10m_populated_places/ne_10m_populated_places.shp

Finally, I merged subunits.json and places.json into a single TopoJSON file, with the added bonus that TopoJSON is much much smaller than GeoJSON. The source GeoJSON weighed in at 549 KB whereas the combined TopoJSON is a mere 78 KB.

$ topojson --id-property su_a3 -p NAME=name -p name -o great-british-map.json subunits.json places.json

The main reason for use of TopoJSON is not that it’s much more lightweight than GeoJSON, but that Mike Bostock’s excellent D3 JavaScript library can easily slurp in TopoJSON and inject SVG straight into an HTML document. Which is precisely what the map’s underlying code does. There’s a lot more that D3 could do with this map, but it’s early days and for a first step into a new maps library, I’m pretty happy with how it’s turned out.

Speaking of code, it should come as no surprise that the map’s code base is available on GitHub. The Great British Map is based on great D3 tutorial that Mike has written on vector mapping using Natural Earth, so the similarity between Mike’s map and my map is entirely intentional.

Written and posted from home (51.427051, -0.333344)

You Were Here; Mapping The Places I’ve Been To According To Foursquare

Over the weekend I made another map. While I don’t think for one moment this one will be as wildly popular as my last map was, this one is just as satisfying and a whole lot more personal.

At 8.01 PM on the 11th. of October 2009 I checked into Sushi Tomi in Mountain View, California. This was my very first Foursquare check-in. Since then I’ve checked-in on this particular location based service a further 12,394 times. Each check-in has been at a place I’ve visited. As this is a location based service, each check-in comes with a longitude and latitude.

This sounded to me like an ideal candidate for a map. But how to go about making one?

Checkins - Global

I could have written some code to use the Foursquare API, but I’ve been running an instance of Aaron Cope‘s privatesquare for a couple of years now, which meant every check-in I’ve ever made, give or take the last 6 hours or so, is sitting comfortably in a MySQL database.

So I wrote some code to go through the database, extract each checkin and make a list of each place I’d checked into, the place’s coordinates, the place’s name and how many times I’d checked into that place. Armed with this information, I could then spit this out in GeoJSON format, which made making a map no more complicated than some mapping API JavaScript, in this case the Leaflet API. OK. There was some slight complication. I need to do some cleverness to make each checkin a CircleMarker, where the radius of the circle was proportional to the number of check-ins. Thankfully Mike Bostock’s D3 library does this with ease.

It’s not the most classy of visualisations. But I do like that the map shows me the global picture of where I’ve been over the last 4 or so years. As you zoom into the map, it’s fascinating to see the patterns of my movements in areas I seem to go to on a regular basis, such as the San Francisco Bay Area …

Checkins - Bay Area

… or Berlin …

Checkins - Berlin

… or even Dar Es Salaam …

Checkins - Dar Es Salaam

… as well as my journeys around my home country.

Checkins - UK

But there’s still a lot of things that the map doesn’t do.

The z-index, or stacking order, of the markers is based on each place’s coordinates; ideally this will be adjusted so that the larger markers, those with the most check-ins, stack underneath the smaller ones so they’re not obscured. I also want to add the ability to see some form of timeline and add some richer data about each place to the marker’s popups.

But for now, it does the job I set out to do and to make life easier, should you wish to do the same, you’ll find the source code up on GitHub.

What next? Well, now that I can download my Twitter history, I think all of my geotagged tweets are suitable candidates for some mapping …

Written and posted from home (51.427051, -0.333344)

Mapping Meteor Strikes; There’s A Lot More Than You’d Think

Last week’s 10,00 ton and 55 feet’s worth of meteor that exploded over and hit the Russian city of Chelyabinsk in the Urals made several thoughts go through my mind. In this order.

  1. I feel for the 1200 people who were hurt and injured
  2. Thank goodness it didn’t happen where I live
  3. With all the asteroids and smaller pieces of rock zooming over our head, this has got to have happened before, hasn’t it?

On the subject of the last thought, it turns out this has happened before. A few times. Actually close to 35,000 times. The Meteoritical Society has a data set detailing these. It would make a great map. Which is exactly what Javier de la Torre, co-founder of CartoDB has done.

Meteor Map - Global

A map of impact points would be effective enough, but Javier’s use of a heatmap not only shows the global spread of the debris which has been raining down on our planet since 2,300 BC but also shows the density of strikes, which makes the map simultaneously more effective and accessible.

Meteor Map - UK

There’s also been far more strikes in the United Kingdom than I would have either thought or feel vaguely comfortable about, if you can ever be comfortable with things falling from the sky with horrifying effect.

Definitely a map to file under the I wish I’d done that category.

Written and posted from home (51.427051, -0.333344)

Maps, Maps And MOAR Maps At The Society Of Cartographers And Expedia

Updated September 13th. 2012 with embedded YouTube video.

Wednesday September 5th. 2012 was a day of maps. To be precise, it was a day of maps, maps and MOAR maps. Two events, two talks, back to back. Packed choc-a-bloc full of maps. I also cheated slightly.

Firstly there was the International Cartographical Association’s first session of the newly formed Commission on Neocartography. Cartography, neocartography, maps; what is there not to like? I’d previously spoken at the UK’s Society of Cartographer’s annual conference so it was great to be asked by Steve Chilton, SoC and Neocartography chair, to speak at the Neocartography Commission.

For a change, the talk title and abstract I gave Steve didn’t vary during the usual researching and writing of the talk.


Content-Type: text/plain; charset=us-ascii
Mime-Version: 1.0 (Apple Message framework v1278)
Subject: Re: Neocartography workshop
X-Universally-Unique-Identifier: d1c70302-eaba-4132-80fb-f74eb1de2347
From: Gary Gale
In-Reply-To: DEC2FCE18B20734CAFA668E438482963834F621862@WGFP-EXMBV1.uni.mdx.ac.uk
Date: Fri, 20 Jul 2012 14:13:39 +0100
Content-Transfer-Encoding: quoted-printable
X-Smtp-Server: mail.vicchi.org:redacted
Message-Id: BEB576E2-3E8C-4136-803A-0CE5E5456C26@vicchi.org
To: Steve Chilton

Actually, I'm going to change the title ... what I'd really like to see up on the web site is this ...

Title: History Repeats Itself And So Does The Map
Abstract: Steve Chilton says this just MIGHT be interesting; you'll have to take his word for this

... but that might not work. So try this for size instead

Title: History Repeats Itself And So Does The Map
Abstract: History has a habit of repeating itself and so does the map. From primitive scratchings, through ever more sumptuous pieces of art, through to authoritative geographical representations, the map changes throughout history. Maps speak of the hopes, dreams and prejudices of their creators and audience alike, and with the advent of neogeography and neocartography, maps are again as much art as they are geographical information.

... will that do?

G

But then, no sooner had I got one event for that Wednesday when fellow Yahoo! alumni and now Expedia developer and chief evangelist Steve Marshall asked me to team up with ex-Doppleran and ex-Nokian Matt Biddulph at Expedia’s EAN World of Data event which was cunningly masquerading as a BBQ that very Wednesday evening. So I cheated. One day. Loads of maps. Two events. But one talk. Only time will tell whether I got away with it or not.

Rob de Feo: Natural Language Processing & Gary Gale: Maps @ EAN Developer Network

My talk at the Neocartography workshop was filmed and you can watch it below, if you like that sort of thing. Personally I hate seeing myself on video, it’s even more excrutiating than hearing myself on audio.

As usual, the slide deck, plus notes are embedded below, also if you like that sort of thing.

Read On…

The Death Of The Map Has Been Greatly Exaggerated

Just like RSS, the death of the map has been widely predicted, but to paraphrase Mark Twain, the death of both have been greatly exaggerated. Produce an online data set with some form of geospatial or location content and someone, somewhere, will produce a map of it.

Sometimes the resultant map leaves a lot to be desired, such as the recent UK government’s attempts to map crime across the country. But sometimes, the map shows something much more interesting, topical and relevent, such as the use of social media in the recent events in Egypt.

Hypercities have produced a series of maps “for traveling back in time to explore the historical layers of city spaces in an interactive, hypermedia environment” and have now produced a map showing the Tweet stream during and after the stepping down of Egyptian government.

There has been much debate over social media’s role in the recent changes in Tunisia, Egypt and other Middle Eastern states; I don’t want to get into a debate over how much significance social media and the Internet has played in these events. But almost all wildly differing viewpoints in the debate agree on one thing; that this is a new development and that we’ve never seen this sort of thing before. So I was much amused to read that before Twitter, before Facebook, before social media, the Internet played another role in a revolution.

During 1991′s coup attempt in the then Soviet Union all official media channels were cut off, much in the same way as Egypt threw their Internet kill switch recently. But in 1991, the computer networks remained up and news of the coup was spread via Usenet. Maybe information really does just want to be free.

Written and posted from home (51.427051, -0.333344)

Visualising Twitter’s Geotagged Tweets

You might have noticed but I’m a reasonably big Twitter user. Actually, I should be more precise. I’m a reasonably big Twitter API user … I tend to use Tweetdeck on my mobile devices and on my laptop. I very rarely use Twitter on the web, and so I’ve only just noticed how Twitter are handling the display of geotagged Tweets. Take a look below and you’ll see that on the accompanying map that they’re rolling up from the point of the geocode to the nearest administrative geographic entity and highlighting this in a rather fetching shade of transparent red.

For Tweets at home, the geotag rolls up to the London Borough of Richmond-upon-Thames, although I had to check this as I was pretty sure the Borough didn’t have that shape; I was wrong on that count.

In Berlin, the geotag rolls up to the Bezirke or borough, as shown in the example below, Tweeted from Berlin’s Tegel airport. The vector of Reinickendorf can clearly be seen.

But sometimes the vector data just isn’t there. The final example, Tweeted from Hampshire merely shows what I assume is the minimum bounding rectangle for the county.

As a final note, this feature doesn’t appear in the “new” version of Twitters web site, where only the name of the geotag’s location is displayed; if you want to see this in action yourself, you’ll have to switch off the “new” version’s preview and revert to the older user interface.

Written and posted from the Nokia Office, Boston, MA (42.35071, -71.07146)

Where’s My Tube Train? Ah, There’s My Tube Train

Back in December of 2009, I wrote about Paul Clarke trying to solve the problem of where’s my train;┬áthat there must be a definitive, raw source of real-time (train) information and that

I assert that train operators know where their assets are; it would be irresponsible if they didn’t

Whilst the plethora of train operators that fragmented from the ashes of the old British Rail network haven’t answered this challenge yet, Transport for London has, opening up just such data as part of the London Datastore API. In today’s age of talented web mashup developers, if you release an API people will build things with it if the information is useful and interesting and that’s just what Matthew Somerville of MySociety did at the recent Science Hack Day … a (near) realtime map of the London Underground showing the movement of trains of all of the Tube lines. A screen grab wouldn’t do it justice and it takes a while to load, so a video grab might help here.

Coming down the escalators at Waterloo and want to know whether to head for the Bakerloo or the Northern Line to take you north of the river? Now you can tell which line has a northbound train closest to Waterloo.

Want to see just how close the gap is between Leicester Square and Covent Garden on the Piccadilly Line really is? Now you can.

Of course, this doesn’t solve every problem …

  1. If you’re on the escalators at Waterloo how do you get 3G data coverage to view this mashup on your phone as Transport for London still haven’t manage to achieve cellular coverage underground, unlike Amsterdam, Berlin and other cities?
  2. The site will probably be the target of a tutting campaign from the Health and Safely police insisting that such a visualisation will cause people to run for the train and of course, they might trip and hurt themselves.
  3. If you’re at the top of the escalator and the train is in the station, now, right this very minute now, how do you get down to the platforms quickly?

Whilst I can’t answer the first two of these questions, this publicity stunt from Volkswagon at Berlin’s Alexanderplatz U-Bahn station might just hold the solution for the third question … a slide!

Written and posted from the Ramada Hotel Berlin Mitte in Berlin (52.529858, 13.383858)

Visualising Tag Clouds

If you haven’t played with Wordle yet, I strongly suggest you point your browser of choice there right now and see what gorgeous visualisations of tags it comes up with. This is my delicious tag cloud …

Playing with tag clouds: http://delicious.com/vicchi

… this is the tag cloud for this blog

Playing with tag clouds: http://www.vicchi.org/

… and this is the tag cloud for the blog I write for work.

Playing with tag clouds: http://www.ygeoblog.com/

All of which were produced using the default settings, with no tweaking, shows just how varied my personal approach to tagging is and how strongly tied to usage my tags are.

Written and posted from home (51.427051, -0.333344)