Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #31052
| Newsgroups | comp.lang.python |
|---|---|
| Date | 2012-10-09 11:02 -0700 |
| Message-ID | <ba5ade32-dfd4-4443-a569-c7488cd77659@googlegroups.com> (permalink) |
| Subject | Getting ipython notebook to plot inline |
| From | Frank Franklin <fr4nkl1nz@gmail.com> |
I've just managed to install ipython and get it to run by typing ipython notebook --pylab=inline
Now I'm getting the following error when I try to plot something in ipython notebook:
AttributeError: 'module' object has no attribute 'FigureCanvas'
I've tried using imports to make this work:
import matplotlib.pyplot as plt
import numpy as np
x = np.arange(0, 5, 0.1);
y = np.sin(x)
plt.plot(x, y)
But for some reason I still get this error. Anybody else know what's going on here? All of the print statements I've done before have worked, and I actually got my plots to work when I didn't set --pylab=inline, though they came up in a separate window and I want them to stay in the ipython notebook.
Back to comp.lang.python | Previous | Next — Next in thread | Find similar | Unroll thread
Getting ipython notebook to plot inline Frank Franklin <fr4nkl1nz@gmail.com> - 2012-10-09 11:02 -0700 Re: Getting ipython notebook to plot inline [updated] Frank Franklin <fr4nkl1nz@gmail.com> - 2012-10-11 07:45 -0700
csiph-web