After a few days of fiddling with it, I’ve finally managed to use the Google Charts API to create a simple interactive timepoint-delay plot of prion therapeutics tested in vivo.  Here it is:

And here is another version, zoomed in on the i.c. experiments:

From now on, these and any subsequent improvements on them will be on the therapeutic review page. I’m posting them here mostly for my own future reference, as well as to get feedback on content and technical issues.

wishlist

  • Display different classes of therapeutic – vaccinations, antibodies, polymers, small molecules, etc. – as different series with different colors
  • Checkboxes to turn different series on and off
  • Free text search to highlight a given experiment
  • Type in the data from an unpublished experiment and see how it will stack up
  • PubMed links inside tooltips  - this and this make me think it’s hard to do right, but how does PubMed Central do it?
  • Allow user to choose axis limits

technical issues

  • This is implemented as a ScatterChart, which I honed in the Code Playground before putting up.  The process for creating it is totally not how it ought to be done:
  • Currently I use this R Script on this data file to generate this JavaScript.  I embed the data directly in the JavaScript because I couldn’t figure out how to adapt this example of reading data from a Google Spreadsheet or other data source to a ScatterChart.
  • Once the JavaScript is created I insert it in between WP-No-Format tags, which break every time you toggle between HTML and Visual editors in WordPress, so adding the code has to be the last thing I do before I update the page/post.  I tried putting the JS in a Custom Field instead, but when I do that, nothing happens.