ipython notebook and matplotlib

In order to have the plots to be shown within a ipython notebook, you should include the following code at the beginning.

%pylab inline

Images may be tiny. You can set the size by playing with the matplotlib configuration file.

matplotlib.rcParams['savefig.dpi'] = 2 * matplotlib.rcParams['savefig.dpi']

See the notebook for an example within nbviewer


Please follow and like us:
This entry was posted in Python and tagged , . Bookmark the permalink.

Leave a Reply

Your email address will not be published.