[okfn-labs] PyBossa Stats

Daniel Lombraña González teleyinex at gmail.com
Tue Oct 23 15:51:45 UTC 2012


Dear all,

I would like to share with you the first version of an application that
creates some charts for PyBossa applications. The tool basically generates
an HTML page that loads some data regarding the participation of the users,
so you can for example know who is participating more: anonymous or
authenticated users, the most popular hour of the day for the project (when
users answer more questions), web map of the volunteers, etc.

The tool uses several technologies for displaying the data:


   - nvd3.js for drawing the charts
   - leaflet.js for drawing a map for the anonymous volunteers
   - GeoIP.dat for computing the latitude and longitude based on IP
   addresses
   - Jinja2 for HTML rendering

Additionally, the tool exports the data to a folder with the same name of
the project, and includes an option to "anonymize" the user data. More
concretely the tool uses the following "techniques":

   - Replace all the IP addresses with Fake ones (out of the range of a
   normal IP address)
   - Adds an error to the Lat/Lng values, just to not show exactly the
   location of the IP --bear in mind that GeoIP is not 100% accurate in its
   lite version too.
   - Replace the PyBossa user ID with random numbers (including negative
   ones).

Thanks to these approaches, the owners of the applications can set up a
CRON job to update every hour the stats of their application, and share
them (if the want) on a web server with the public thanks to the
"anonimizer feature".
The tool is in it is early stages but it is working. Tomorrow I'll be
working in cleaning the code and publish it into Github, but for the moment
here you have some Stats for the applications Urban Parks and Flickr
Person. I hope you like it:

http://dl.dropbox.com/u/27667029/flickrperson.zip
http://dl.dropbox.com/u/27667029/urbanpark.zip
http://dl.dropbox.com/u/27667029/screenshot.png

In order to see the output, just unzip the ZIP files and open with a modern
web browser the index.html file. It should work out of the box in FF >=16.0
and Chrome >= 22.0.

Cheers,

Daniel

-- 
··························································································································································
http://github.com/teleyinex
http://www.flickr.com/photos/teleyinex
··························································································································································
Por favor, NO utilice formatos de archivo propietarios para el
intercambio de documentos, como DOC y XLS, sino PDF, HTML, RTF, TXT, CSV
o cualquier otro que no obligue a utilizar un programa de un
fabricante concreto para tratar la información contenida en él.
··························································································································································
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.okfn.org/pipermail/okfn-labs/attachments/20121023/1b6fa02f/attachment-0001.html>


More information about the okfn-labs mailing list