Dom asked me on IRC yesterday about the code that generates the OGL node statistics (http://london.openguides.org/statistics/). I've now modulized it. Please test this:
http://downlode.org/tmp/Openguides-Statistics-1.tar.gz
I've not been able to test it against any databases other than the current London one (PgSQL), so I have no idea if it will work for others, although I've tried to write it so that it will. I also only have some very basic tests for it because I don't know how to write tests for something that relies on a database.
Cheers,
Earle.