Charting data from our tables using matplotlib - How to export an image with matplotlib