Geolocation, Mobile Web Apps, Geo-Autocomplete, Geohashing, and more from GeoMeme
November 23rd, 2009 | Published in Google Maps
Guest post by Bob Hitching, Director of Technology for Xumii, recently acquired by Myriad (Myriad Group AG), Europe's largest mobile technology company with software in over 2 billion phones.Bob also writes about mobile + geo + social on his blog and tweets as @hitching.
GeoMeme is a pet project of mine. It's a web app, and also a mobile web app for iPhone and Android, that measures real-time local twitter trends to work out what's happening where.
Visitors to GeoMeme choose a location on the map, and two search terms to compare. GeoMeme then measures and compares the number of matching tweets within the bounds of the map. Tweets are located using Twitter's brand new geotagging feature, and public data from a number of mobile twitter apps.
As an example, GeoMeme can work out that 'love' beats 'hate' in New York:
GeoMeme is packed full of geo goodness, and I am excited to share some details on how it all works in the following articles. I hope these are useful to those of you building your own geo apps.
Location-aware mobile web apps using Google Maps v3 + geolocation
This article explains how location-aware mobile web apps such as GeoMeme Mobile are now becoming a viable alternative to native mobile apps for iPhone &/or Android.
Also covered is how to combine various geolocation techniques to work out where on earth a mobile phone is located, and how to dynamically retrieve content local to the user for display on a mobile map.
Sample code is provided in the form of a 'Here I Am' location-aware mobile web app that combines geolocation techniques, and retrieves local photos from Panoramio for sharing on Twitter or Facebook.
Fast map re-location using Google Static Maps v2 + geocoder
As well as offering users the normal pan and zoom controls to move the map around, GeoMeme also adds an innovative geo-autocomplete control which provides a refreshingly quick way for users to re-position the map anywhere on the planet.
This article explains how the geo-autocomplete control uses the geocoder service from Google Maps v3 API to match location names as they are being typed, and then the new Static Maps v2 API to present the results as a menu of map thumbnails to choose from.
Sample code is provided in the form of a jQuery plugin for you to build your own geo-autocomplete controls.
Scalable, fast, accurate geo apps using Google App Engine + geohash + faultline correction
GeoMeme generates a large amount of geo-data, and so arises a need shared by many geo apps: scalable, fast, and accurate spatial queries, to select a subset of geo-data for display as markers on a map.
This article is all about using Google App Engine to host scalable and fast geo apps, and using an optimised version of the geohash algorithm to perform your spatial queries.
There's a fun demo showing the effect of geohash faultlines, and the relative accuracy of spatial queries with or without faultline correction
Sample code is provided as a python module to handle faultline-friendly geo search, if you want to use this technique on your own geo apps.