Sponsored Links

Technical Overview: Geocoder.US PDF Print E-mail
Written by Richard Marsden   
Monday, 02 November 2009 12:17

Geocoder.US is a popular online geocoding service. The service supports geocoding through REST, XML-RPC, SOAP, web interface, and email. Limited services are free for non-commercial purposes. Batch geocoding is also available for commercial users.

 

The various Geocoder.us services can be found at Geocoder.us and the Geocoder.net synonym. Geocoder supports a mix of commercial and non-commercial geocoding services using a range of different protocols. The range of protocols and free non-commercial services make it a popular choice for geospatial mashups and book examples.

The underlying geocoder is based on the public domain TIGER/Line data from the US Census Bureau, and it is currently using the 2004 version. TIGER/Line data updates are infrequent and data quality is variable. Urban locations are often within 10m (ie. better than many consumer GPS devices), but sometimes errors can be much larger.

Coordinate results use the NAD83 datum for the 48 contiguous states, Alaska, Puerto Rico, and the US Virgin Islands. Regional datums are used for Hawai'i and the Pacific Island areas. Geocoder.us only supports the US and its territories.

The geocoding algorithm is based on the open source Geo::Coder::US Perl module, which has been made available through CPAN. Therefore you are free to use this module to implement your own local geocoder if you have access to appropriate data for your region, or a better source of US data.

Geocoder.us has a simple demonstration website that can be used to geocode individual addresses through a web interface. The web services are much more useful. These support SOAP, XML-RPC, and REST. Examples in the documentation include PHP, PERL, C#, and ASP. Anyone with some experience of web services in their language of choice should have no problems adapting these examples to their own language.

RESTful services are definitely in vogue, and modern developers probably prefer to use a simple RESTful service rather than the more complicated SOAP approach. Geocoder.us supports two RESTful services: RDF and CSV. The following example, taken from the documentation, is a simple PERL fragment that uses the commercial RDF service and parses the response:

  1 
  2 
  3 
  4 
  5 
  6 
  7 
  8 
  9 

 10 
 11 
 12 
 13 
    use RDF::Simple::Parser;
    use URI::Escape;
    use Data::Dumper;

    my $addr = uri_escape( "1600 Pennsylvania Ave, Washington, DC" );

    my @result = RDF::Simple::Parser
    ->new
    ->parse_uri( 
      "http://username:password\@geocoder.us/member/service/rest/geocode"
        . "?address=$addr" );

    print Dumper \@result;

 

Here is the parsed response:

  1 
  2 
  3 
  4 
  5 
  6 
  7 
  8 
  9 
 10 
 11 
 12 
 13 
 14 
 15 
 16 
 17 
 18 
 19 
 20 
 21 
 22 
 23 
@result = (
          [
            '_:id4280ab4aa61e',
            'http://www.w3.org/1999/02/22-rdf-syntax-ns#type',
            'http://www.w3.org/2003/01/geo/wgs84_pos#Point'
          ],
          [
            '_:id4280ab4aa61e',
            'http://purl.org/dc/elements/1.1/description',
            '1600 Pennsylvania Ave NW, Washington DC 20502'
          ],
          [
            '_:id4280ab4aa61e',
            'http://www.w3.org/2003/01/geo/wgs84_pos#long',
            '-77.037684'
          ],
          [
            '_:id4280ab4aa61e',
            'http://www.w3.org/2003/01/geo/wgs84_pos#lat',
            '38.898748'
          ]
        );

 

The CSV option returns simple comma separated value text. This is probably easier to parse for many applications.

Although Geocoder.us is free for non-commercial applications, there are fees for commercial applications and batch geocoding. Compared to competing commercial services, these are very cheap: US$50 per 20,000 address (US$50 minimum, pro rata after that). This is paid in advance to enable the commercial variant of the web services; or batches can be sent by email. Email batches should use CSV or Excel files, although Geocoder.us can support other formats with additional fees.

So, in summary, Geocoder.US is a very useful online geocoding service. Accuracy and data completeness can be a problem, but competing systems cost substantially more for commercial applications.


Comments (3)Add Comment
0
Gecoder.us updated
written by Sean Gorman, November 02, 2009
Schuyler recently updated GeoCoder.us. You can find the latest here:

http://github.com/geocommons/geocoder
0
ESRI is offering similar service (including North America), but with commercial street data (ie: supposedly more accurate).
written by James Harding, November 09, 2009
Second page of http://www.esri.com/software/a...rvices.pdf has pricing.

$50 for 25,000 addresses.

FREE for non-commercial - but I'm not sure what their definition of non-commercial is.
62
Thanks James
written by Richard Marsden, November 09, 2009
Thanks for the info James. Also there's "Geonames.org", for which I have an article pending (probably due to be published in January). WGeonames isn't a true geocoder, but the entire database can be downloaded - something I have found useful for an ongoing project. This required lists of cities with population and coordinate information. In the past I used US Census Bureau data for the US, but I had to expand the project to other countries.

Write comment

security code
Write the displayed characters


busy