From: Matthew B. <mat...@gm...> - 2014-07-30 17:36:09
|
Hi, On Wed, Jul 30, 2014 at 10:26 AM, Nathan Goldbaum <nat...@gm...> wrote: > You would use "%matplotlib inline" if you want the plots to show up inline > in the notebook. If you want to use one of the gui backends, it would be > "%matplotlib <backend>". More detail here: > > http://ipython.org/ipython-doc/2/api/generated/IPython.core.magics.pylab.html#IPython.core.magics.pylab.PylabMagics.matplotlib > > Pylab is going to be removed in IPython 3.0 (in fact it's already gone in > master) since it has several bad interactions with the rest of the > numpy/scipy universe and leads to un-reproducible code. See this blog post > for more detail on why using pylab is a bad idea: > > https://carreau.github.io/posts/10-No-PyLab-Thanks.ipynb.html I personally use the IPython console for my just-checking interactive work, rather than the notebook. Checking now, '%matplotlib inline' in the console raises an error, understandably enough, but this works: %matplotlib osx import matplotlib.pyplot as plt plt.plot(range(10)) I know that's what you said, it's just to give a complete snippet for Googlers, Cheers, Matthew |