Wednesday, July 20, 2011

Another Take on Visualizing Collections

Today we released a new feature to Mantis--charts and graphs with the handy jQuery plugin Visualize by the Filament Group. This converts HTML tables of data generated dynamically from Solr queries into line, bar, area, and pie charts that are rendered with the HTML5 canvas element. This works in any modern browser (Opera, Safari 3+, Google Chrome, and Firefox 3.5+), though I have found that IE8 has some rendering issues.

The new Visualize feature functions as an extension to the search results page. A chart icon appears in the top of the left-hand column, under "Data Options" (alongside Atom, KML, and CSV deliverables). This will direct the user to a new page with various data and chart output options. The user can select to render a graphical tabulation of available Solr facets given the current query passed via parameter from the search results page. For example, one can receive a chart of deities given the query of Roman coins minted in Asia, Asia Minor, Caesarea, Carrhae, or Carthage. The result is pictured below.


The Solr query and all chart options are passed into the page via URL parameters rather than relying on asynchronous javascript interaction. This means that specific charts have URIs and can thus be bookmarked and passed to others for viewing, e.g., http://bit.ly/r3FUDj. Moreover, the charts are printable!