From: Chris C. <scc...@gm...> - 2009-11-30 10:20:38
|
On Sat, Nov 28, 2009 at 6:56 PM, Gary Pajer <gar...@gm...> wrote: > PyLab is new to me, but I am familiar with pylab (matplotlib sub). I also > strongly suspect that matplotlib is what you want. You don't say what > platform you are on, but matplotlib is included in the Ubuntu installation > repository. I've found the easiest way to install matplotlib on WinXP is > using the stand-alone installer on their website. I think they offer an > "easy_install" option, but I've gotten tied up in knots with that from time > to time. > > Now, since Bruce brought it up ... > > One problem with "from pylab import *" is that matplotlib overwrites some > numpy functions, for example linspace(). I don't know why or how that > happened, but the two functions behave differently. People probably expect > the numpy behavior, but unexpectedly get the matplotlib behavior. > > Perhaps PyLab does away with this conflict. I don't know. > That is incorrect: In [1]: import pylab as pl In [2]: pl.linspace Out[2]: <function linspace at 0x2763c80> In [3]: import numpy as np In [4]: np.linspace Out[4]: <function linspace at 0x2763c80> They are the same function. > > > On Thu, Nov 19, 2009 at 4:10 PM, Bruce Sherwood <Bru...@nc...> > wrote: >> >> After a bit of googling, the situation seems to be this: >> >> matplotlib (http://matplotlib.sourceforge.net) is a Python 2d plotting >> library >> which includes a module named pylab. I'm guessing that's what you're >> looking for. >> >> A confusing factor is that at http://www.scipy.org/PyLab there is a >> discussion >> that starts out with this: >> >> See the following post for further discussion of the difference between >> the >> vision for a new PyLab expressed on this page, and the existing pylab >> package >> which is part of matplotlib: >> http://www.nabble.com/pylab-td24910613.html >> >> Incidentally, the www.scipy.org/PyLab discussion makes a case for a new >> pylab to >> be invoked as "from pylab import *" which would import a bunch of stuff >> almost >> anyone doing scientific processing will need (including numpy and scipy), >> rather >> like the current situation with Visual. The essayist then says, foreseeing >> objections, "But there are so many names! Not really. from scipy import * >> brings >> in about 20 subpackages (i.e. signal such that you still need to do >> signal.ifft, >> but not scipy.signal.ifft) and only 15 new symbols." >> >> Bruce Sherwood >> >> marco bittelli wrote: >> > I am trying to install pylab for python 2.6, but I have problem finding >> > the package (even in the main Python website). >> > >> > >> > >> > Could you help me ? >> > >> > >> > >> > Marco >> > >> > >> > >> > Marco Bittelli, Ph.D. >> > >> > Department of Agro-Environmental Science and Technology >> > >> > University of Bologna, Italy >> > >> > Viale Fanin, 44. >> > >> > 40125, Bologna, Italy >> > >> > email:mar...@un... >> > >> > http://www.dista.unibo.it/~bittelli >> >> >> ------------------------------------------------------------------------------ >> Let Crystal Reports handle the reporting - Free Crystal Reports 2008 >> 30-Day >> trial. Simplify your report design, integration and deployment - and focus >> on >> what you do best, core application coding. Discover what's new with >> Crystal Reports now. http://p.sf.net/sfu/bobj-july >> _______________________________________________ >> Visualpython-users mailing list >> Vis...@li... >> https://lists.sourceforge.net/lists/listinfo/visualpython-users > > > ------------------------------------------------------------------------------ > Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day > trial. Simplify your report design, integration and deployment - and focus > on > what you do best, core application coding. Discover what's new with > Crystal Reports now. http://p.sf.net/sfu/bobj-july > _______________________________________________ > Visualpython-users mailing list > Vis...@li... > https://lists.sourceforge.net/lists/listinfo/visualpython-users > > |