Code accompanying my talk at code4libbc, November 2014