Latest Updates

Ruby Version

October 28, 2012

I've started a port to Ruby. It's functionally complete, with the same exact (minimal) tests as the Perl and JS versions, and it just needs to be packaged and documented. You can find it on github at

Java Version

September 10, 2012

I just discovered that someone has ported the API to Java - Go here to check it out. I love that people take the time to do stuff like that. Thanks!

New Perl Version (0.33)

Feb 27, 2012

Last night I pushed out a new version of the Perl module. It's available from CPAN, or if for some reason you don't want to install it from CPAN, you can grab the source from github. All links are on the downloads page.

Greenwich Bug Fixed

Feb 26, 2012

There was a bug in the neighboursWithinRadius function - it was not working correctly if the circle crossed the Greenwich Meridian. That should be fixed now, and available on github.

Welcome Hacker News Folks!

Feb 25, 2012

If you're coming from hacker news because you're curious about the site, you should probably head over to the FAQ to get the gist, and then to the google maps demo to see how it all fits together.

Radius Searching

Feb 25, 2012

Today I added something to the JS library that's pretty cool: given a GeoDNA code and a radius, it generates the minimal covering set of all GeoDNA codes required to represent that radius. In terms of real-world applications, this is useful because you often want to perform radius-based searching centred on a specific point.

For example, if you wanted to perform a proximity search of your data to find all records within 40km of "wtaatcagtca" (Cuzco, Peru), then you call

    var neighbours = GeoDNA.neighboursWithinRadius( "wtaatcagtca", 40, { precision: 11 } );
    ["wtaatcagcta", "wtaatcagcgt", "wtaatcagctg", "wtaatcagctt",
     "wtaatcagtac", "wtaatcagtca", "wtaatcagtcc", "wtaatcatgaa",
     "wtaatcagtat", "wtaatcagtcg", "wtaatcagtct", "wtaatcagtta"]

you will get back a set of codes, often of different sizes (but never smaller than precision 11), that entirely cover the circle of radius 40km around Cuzco.

You can then find any records in that area by simply locating all your records whose GeoDNA starts with any of those codes. Text-based prefix searching is usually extremely fast.

Check out the google maps demo to see the system generate these covering codes.