ENH: add better storage mechanism and cleaner plotting code