You can subscribe to this list here.
| 2003 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(3) |
Jun
|
Jul
|
Aug
(12) |
Sep
(12) |
Oct
(56) |
Nov
(65) |
Dec
(37) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2004 |
Jan
(59) |
Feb
(78) |
Mar
(153) |
Apr
(205) |
May
(184) |
Jun
(123) |
Jul
(171) |
Aug
(156) |
Sep
(190) |
Oct
(120) |
Nov
(154) |
Dec
(223) |
| 2005 |
Jan
(184) |
Feb
(267) |
Mar
(214) |
Apr
(286) |
May
(320) |
Jun
(299) |
Jul
(348) |
Aug
(283) |
Sep
(355) |
Oct
(293) |
Nov
(232) |
Dec
(203) |
| 2006 |
Jan
(352) |
Feb
(358) |
Mar
(403) |
Apr
(313) |
May
(165) |
Jun
(281) |
Jul
(316) |
Aug
(228) |
Sep
(279) |
Oct
(243) |
Nov
(315) |
Dec
(345) |
| 2007 |
Jan
(260) |
Feb
(323) |
Mar
(340) |
Apr
(319) |
May
(290) |
Jun
(296) |
Jul
(221) |
Aug
(292) |
Sep
(242) |
Oct
(248) |
Nov
(242) |
Dec
(332) |
| 2008 |
Jan
(312) |
Feb
(359) |
Mar
(454) |
Apr
(287) |
May
(340) |
Jun
(450) |
Jul
(403) |
Aug
(324) |
Sep
(349) |
Oct
(385) |
Nov
(363) |
Dec
(437) |
| 2009 |
Jan
(500) |
Feb
(301) |
Mar
(409) |
Apr
(486) |
May
(545) |
Jun
(391) |
Jul
(518) |
Aug
(497) |
Sep
(492) |
Oct
(429) |
Nov
(357) |
Dec
(310) |
| 2010 |
Jan
(371) |
Feb
(657) |
Mar
(519) |
Apr
(432) |
May
(312) |
Jun
(416) |
Jul
(477) |
Aug
(386) |
Sep
(419) |
Oct
(435) |
Nov
(320) |
Dec
(202) |
| 2011 |
Jan
(321) |
Feb
(413) |
Mar
(299) |
Apr
(215) |
May
(284) |
Jun
(203) |
Jul
(207) |
Aug
(314) |
Sep
(321) |
Oct
(259) |
Nov
(347) |
Dec
(209) |
| 2012 |
Jan
(322) |
Feb
(414) |
Mar
(377) |
Apr
(179) |
May
(173) |
Jun
(234) |
Jul
(295) |
Aug
(239) |
Sep
(276) |
Oct
(355) |
Nov
(144) |
Dec
(108) |
| 2013 |
Jan
(170) |
Feb
(89) |
Mar
(204) |
Apr
(133) |
May
(142) |
Jun
(89) |
Jul
(160) |
Aug
(180) |
Sep
(69) |
Oct
(136) |
Nov
(83) |
Dec
(32) |
| 2014 |
Jan
(71) |
Feb
(90) |
Mar
(161) |
Apr
(117) |
May
(78) |
Jun
(94) |
Jul
(60) |
Aug
(83) |
Sep
(102) |
Oct
(132) |
Nov
(154) |
Dec
(96) |
| 2015 |
Jan
(45) |
Feb
(138) |
Mar
(176) |
Apr
(132) |
May
(119) |
Jun
(124) |
Jul
(77) |
Aug
(31) |
Sep
(34) |
Oct
(22) |
Nov
(23) |
Dec
(9) |
| 2016 |
Jan
(26) |
Feb
(17) |
Mar
(10) |
Apr
(8) |
May
(4) |
Jun
(8) |
Jul
(6) |
Aug
(5) |
Sep
(9) |
Oct
(4) |
Nov
|
Dec
|
| 2017 |
Jan
(5) |
Feb
(7) |
Mar
(1) |
Apr
(5) |
May
|
Jun
(3) |
Jul
(6) |
Aug
(1) |
Sep
|
Oct
(2) |
Nov
(1) |
Dec
|
| 2018 |
Jan
|
Feb
|
Mar
|
Apr
(1) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2020 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(1) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2025 |
Jan
(1) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| S | M | T | W | T | F | S |
|---|---|---|---|---|---|---|
|
1
(2) |
2
(13) |
3
(13) |
4
(11) |
5
(15) |
6
(16) |
7
(1) |
|
8
(2) |
9
(1) |
10
(16) |
11
(19) |
12
(8) |
13
(20) |
14
(9) |
|
15
(2) |
16
(9) |
17
(29) |
18
(14) |
19
(13) |
20
(10) |
21
(1) |
|
22
(3) |
23
(4) |
24
(26) |
25
(11) |
26
(11) |
27
(8) |
28
(4) |
|
29
(2) |
30
(10) |
31
(17) |
|
|
|
|
|
From: Chris N. <ca...@gm...> - 2005-05-13 07:26:45
|
I am trying out quiver using IPython (which I am new to so my apologies if= =20 this is actually a IPython question) and matplotlib .80 and the latest=20 numeric. The code I try and the subsequent error: In [1]: x=3Dones([5,5]) In [2]: quiver(x,x) --------------------------------------------------------------------------- exceptions.TypeError Traceback (most recent call last) C:\Documents and Settings\root\Desktop\<console> C:\Python24\Lib\site-packages\matplotlib\pylab.py in quiver(*args, **kwargs= ) 2137 hold(h) 2138 try: -> 2139 ret =3D gca().quiver(*args, **kwargs) 2140 draw_if_interactive() 2141 except: C:\Python24\Lib\site-packages\matplotlib\axes.py in quiver(self, U, V,=20 *args, **kwargs) 852 if do_scale: 853 Nmax =3D maximum.reduce(maximum.reduce(N)) --> 854 U *=3D (S/Nmax) 855 V *=3D (S/Nmax) 856 N /=3D Nmax TypeError: return array has incorrect type What could be the issue? Thanks for the help. -Chris |
|
From: John H. <jdh...@ac...> - 2005-05-12 19:20:45
|
>>>>> "Ryan" == Ryan Krauss <rya...@co...> writes:
Ryan> I am having a slight problem with my install on FC3 Linux
Ryan> running KDE. When I am developing scripts, I like to
Ryan> generate a lot of plots along the way and want them to
Ryan> refresh every time I run the script. When I run the
Ryan> following code with the TkAgg backend it works o.k., but
Ryan> with the GTKAgg backend, only the second plot updates:
See examples/dynamic_image_gtkagg.py for an example of how to use gtk
to make dynamic plots. You can also do this by manipulating the
interactive setting as discussed on
http://matplotlib.sourceforge.net/interactive.html
You may also want to read this FAQ -
http://matplotlib.sourceforge.net/faq.html#SHOW
Hope this helps...
JDH
|
|
From: Ryan K. <rya...@co...> - 2005-05-12 19:12:00
|
I just installed matplotlib and I am really excited about it. I have
often thought it would be great to have all of the Matlab plotting
capabilities without having to pay for their software and now I have
that and Python. What could be better?
I am having a slight problem with my install on FC3 Linux running KDE.
When I am developing scripts, I like to generate a lot of plots along
the way and want them to refresh every time I run the script. When I
run the following code with the TkAgg backend it works o.k., but with
the GTKAgg backend, only the second plot updates:
from pylab import *
#close('all')
figure(1)
cla()
plot(rand(20),rand(20),'go')
figure(2)
cla()
plot(rand(20),rand(20),'ro')
show()
and uncommenting the close('all') line works fine with TkAgg but sort of
locks things up with GTKAgg.
I will just use TkAgg for now, but was wondering if I can fix this.
Thanks,
Ryan
|
|
From: Ted D. <ted...@jp...> - 2005-05-12 15:33:59
|
Thanks for the tip - figlegend works just fine for my application. I'll
file an enhancement for tracking purposes...
Ted
At 07:29 AM 5/12/2005, John Hunter wrote:
> >>>>> "Ted" == Ted Drain <ted...@jp...> writes:
>
> Ted> Has anyone tried to put a legend in a polar plot? I get an
> Ted> error whenever I try this. To reproduce the error, run the
> Ted> polar plot demo and then do something like:
>
> Ted> legend( ( "test" ) )
> Ted>
> "/group/monte/development/rhe3/tools.0504/lib/python2.4/site-packages/matplotlib/axes.py",
> Ted> line 1869, in get_handles handles.extend(self.patches)
> Ted> AttributeError: PolarAxes instance has no attribute 'patches'
>
>
> Ted> Should I file this as a bug? Thanks, Ted Ted Drain Jet
>
>Maybe a feature request? The problem is deeper than simply adding the
>missing patches attr (which holds a list of patches stored by the
>axes). If you add that (as I just did), you can run legend w/ no
>traceback but no legend either. I think the problem is that the
>legend by default uses the axes coordinate system to place the
>rectangle in which the legend resides is being placed in axes
>coordinates, and the axes coordinate system for polar axes is not the
>same as for rectangular axes and this is fouling up the legend
>placement.
>
>There is a workaround using figlegend
>
> >>> lines = polar(range(10))
> >>> figlegend(lines, ('my label',), 'upper right')
>
>I think it would be nice for polar axes legend to work automagically,
>so you might want to add this as a feature request on the sf site. I
>already fixed the patch/traceback crash, but now it just fails
>silently (no legend, no error). I think I'll add an PolarAxes legend
>NotImplementedError which raises an exceptions and suggests figlegend
>for the time being.
>
>I'm sure there are other surprises one will find when trying to use
>some of the Axes parent methods (eg table) in the PolarAxes. It
>would be nice if these were also indicated with NotImplementedError
>until they are. We can fill these in as we find them.
>
>JDH
|
|
From: John H. <jdh...@ac...> - 2005-05-12 14:29:55
|
>>>>> "Ted" == Ted Drain <ted...@jp...> writes:
Ted> Has anyone tried to put a legend in a polar plot? I get an
Ted> error whenever I try this. To reproduce the error, run the
Ted> polar plot demo and then do something like:
Ted> legend( ( "test" ) )
Ted> "/group/monte/development/rhe3/tools.0504/lib/python2.4/site-packages/matplotlib/axes.py",
Ted> line 1869, in get_handles handles.extend(self.patches)
Ted> AttributeError: PolarAxes instance has no attribute 'patches'
Ted> Should I file this as a bug? Thanks, Ted Ted Drain Jet
Maybe a feature request? The problem is deeper than simply adding the
missing patches attr (which holds a list of patches stored by the
axes). If you add that (as I just did), you can run legend w/ no
traceback but no legend either. I think the problem is that the
legend by default uses the axes coordinate system to place the
rectangle in which the legend resides is being placed in axes
coordinates, and the axes coordinate system for polar axes is not the
same as for rectangular axes and this is fouling up the legend
placement.
There is a workaround using figlegend
>>> lines = polar(range(10))
>>> figlegend(lines, ('my label',), 'upper right')
I think it would be nice for polar axes legend to work automagically,
so you might want to add this as a feature request on the sf site. I
already fixed the patch/traceback crash, but now it just fails
silently (no legend, no error). I think I'll add an PolarAxes legend
NotImplementedError which raises an exceptions and suggests figlegend
for the time being.
I'm sure there are other surprises one will find when trying to use
some of the Axes parent methods (eg table) in the PolarAxes. It
would be nice if these were also indicated with NotImplementedError
until they are. We can fill these in as we find them.
JDH
|
|
From: Cory D. <cd...@st...> - 2005-05-12 07:41:46
|
Hi John,
here is the plotyy help info.
Cory.
>> help plotyy
PLOTYY Graphs with y tick labels on the left and right.
PLOTYY(X1,Y1,X2,Y2) plots Y1 versus X1 with y-axis labeling
on the left and plots Y2 versus X2 with y-axis labeling on
the right.
PLOTYY(X1,Y1,X2,Y2,FUN) uses the plotting function FUN
instead of PLOT to produce each plot. FUN should be a
function handle to a plotting function, e.g. @plot, @semilogx,
@semilogy, @loglog ,@stem, etc. that accepts the syntax H = FUN(X,Y).
PLOTYY(X1,Y1,X2,Y2,FUN1,FUN2) uses FUN1(X1,Y1) to plot the data for
the left axes and FUN2(X1,Y1) to plot the data for the right axes.
[AX,H1,H2] = PLOTYY(...) returns the handles of the two axes created in
AX and the handles of the graphics objects from each plot in H1
and H2. AX(1) is the left axes and AX(2) is the right axes.
See also PLOT, @.
>>
John Hunter wrote:
>>>>>>"Cory" == Cory Davis <cd...@st...> writes:
>
>
> Cory> Hi all, I have now figured out how to do this. It goes
> Cory> something like...
>
> That's the basic idea -- matplotlib has some helper functions to make
> this easier -- see examples/shared_axis_demo.py
>
> What is the signature of plotyy -- I wasn't aware of this function..
>
> JDH
>
>
> -------------------------------------------------------
> This SF.Net email is sponsored by Oracle Space Sweepstakes
> Want to be the first software developer in space?
> Enter now for the Oracle Space Sweepstakes!
> http://ads.osdn.com/?ad_id=7393&alloc_id=16281&op=click
> _______________________________________________
> Matplotlib-users mailing list
> Mat...@li...
> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
--
---------------------------------------------------
Cory Davis
Institute for Atmospheric and Environmental Science
Room 307, Crew Building, Kings Buildings,
University of Edinburgh. Edinburgh EH9 3JN
phone: +44 131 6505092
www: http://www.geos.ed.ac.uk/contacts/homes/cdavis
|
|
From: Ted D. <ted...@jp...> - 2005-05-12 02:23:20
|
What's the best way to control the radial scale in a polar plot? For example, if I have data like this: theta = [ 1, 2, 3, 4, 5 ] rad = [ 10, 20, 30, 40, 50 ] polar( theta, rad ) How do I make the radial scale go from 0 to 80? I tried messing with the ylim doing something like this: gca().set_ylim( ( 80*sqrt(2), 80*sqrt(2) ) ) All that seems to do is to scale the whole plot without changing the axis bounds. If I try to set the grid like this: grids = [ 0, 20, 40, 60, 80 ] lbls = [ "0", "20", "40", "60", "80" ] gca().set_rgrids( grid, lbls, frac=1.05 ) The grid lines draw correctly but the background of the plot doesn't change to fit the new grid lines. Thanks, Ted Ted Drain Jet Propulsion Laboratory ted...@jp... |
|
From: Ted D. <ted...@jp...> - 2005-05-12 02:16:09
|
Has anyone tried to put a legend in a polar plot? I get an error whenever
I try this. To reproduce the error, run the polar plot demo and then do
something like:
legend( ( "test" ) )
File
"/group/monte/development/rhe3/tools.0504/lib/python2.4/site-packages/matplotlib/pylab.py",
line 2173, in legend
ret = gca().legend(*args, **kwargs)
File
"/group/monte/development/rhe3/tools.0504/lib/python2.4/site-packages/matplotlib/axes.py",
line 1881, in legend
handles = [h for h, label in zip(get_handles(), labels)]
File
"/group/monte/development/rhe3/tools.0504/lib/python2.4/site-packages/matplotlib/axes.py",
line 1869, in get_handles
handles.extend(self.patches)
AttributeError: PolarAxes instance has no attribute 'patches'
Should I file this as a bug?
Thanks,
Ted
Ted Drain Jet Propulsion Laboratory ted...@jp...
|
|
From: John H. <jdh...@ac...> - 2005-05-12 01:09:35
|
>>>>> "Cory" == Cory Davis <cd...@st...> writes:
Cory> Hi all, I have now figured out how to do this. It goes
Cory> something like...
That's the basic idea -- matplotlib has some helper functions to make
this easier -- see examples/shared_axis_demo.py
What is the signature of plotyy -- I wasn't aware of this function..
JDH
|
|
From: Cory D. <cd...@st...> - 2005-05-11 23:04:41
|
Hi all,
I have now figured out how to do this. It goes something like...
x=arange(10)
y1=sin(x)
y2=10*cos(x)
rect=[0.1,0.1,0.8,0.8]
a1=axes(rect)
a1.yaxis.tick_left()
plot(x,y1)
ylabel('axis 1')
xlabel('x')
a2=axes(rect,frameon=False)
a2.yaxis.tick_right()
plot(x,y2)
a2.yaxis.set_label_position('right')
ylabel('axis 2')
a2.set_xticks([])
Cheers,
Cory.
Cory Davis wrote:
> Hi All,
> I am wanting to make a plot with a secondary y axis, just like the
> matlab function plotyy does. Does anyone have any tips on how to do this
> with matplotlib?
>
> Cheers,
> Cory.
>
>
|
|
From: Chris B. <Chr...@no...> - 2005-05-11 22:00:19
|
Robert Kern wrote:
> /usr/bin = Apple
> /usr/local/bin = Anybody else
For completeness' sake, that's the same rule for EVERY *nix (replacing
"Apple" with whatever OS vendor your using)
-Chris
--
Christopher Barker, Ph.D.
Oceanographer
NOAA/OR&R/HAZMAT (206) 526-6959 voice
7600 Sand Point Way NE (206) 526-6329 fax
Seattle, WA 98115 (206) 526-6317 main reception
Chr...@no...
|
|
From: Robert K. <rk...@uc...> - 2005-05-11 21:39:23
|
Fernando Perez wrote: > Robert Kern wrote: > >> Fernando Perez wrote: >> >>> Matt Newville wrote: >> >>>> Maybe you want to make Mac installs put ipython in /usr/bin >> >> /usr/local/bin, please. > > Well, the point is that I don't want to make it go _anywhere_ in > particular. I want to let distutils do what it's supposed to do, so that > relocation commands (--home, --prefix) work correctly, for example, or > that installs with non-standard pythons also work as they should. Which > is why I'm resisting hard-coding _any_ paths in there, unless I can be > convinced that the solution is a clean one across the board, addressing > all these issues. Yes, that was more advice directed to Matt and anyone else actually installing on OS X than it was to you. /usr/bin = Apple /usr/local/bin = Anybody else -- Robert Kern rk...@uc... "In the fields of hell where the grass grows high Are the graves of dreams allowed to die." -- Richard Harter |
|
From: Fernando P. <Fer...@co...> - 2005-05-11 21:32:49
|
Robert Kern wrote: > Fernando Perez wrote: > >>Matt Newville wrote: > > >>>Maybe you want to make Mac installs put ipython in /usr/bin > > > /usr/local/bin, please. Well, the point is that I don't want to make it go _anywhere_ in particular. I want to let distutils do what it's supposed to do, so that relocation commands (--home, --prefix) work correctly, for example, or that installs with non-standard pythons also work as they should. Which is why I'm resisting hard-coding _any_ paths in there, unless I can be convinced that the solution is a clean one across the board, addressing all these issues. cheers, f |
|
From: Robert K. <rk...@uc...> - 2005-05-11 21:23:19
|
Fernando Perez wrote: > Matt Newville wrote: >> Maybe you want to make Mac installs put ipython in /usr/bin /usr/local/bin, please. >> and >> point to pythonw (which is admittedly just a bash wrapper around >> /System/Library/..../Python.app/Contents/MacOS/Python)?? > > Mmh, the problem is that I don't know how to achieve this in a clean, > distutils-based way. I can't go changing the shebang line by hand, > since I don't know where things will end up, and as far as I know there > is no way to force this kind of behavior onto distutils. FWIW, with the semi-official 2.4.1 framework build, I always get an appropriate #!/usr/bin/env /usr/local/bin/pythonw2.4 -- Robert Kern rk...@uc... "In the fields of hell where the grass grows high Are the graves of dreams allowed to die." -- Richard Harter |
|
From: Cory D. <cd...@st...> - 2005-05-11 21:06:51
|
Hi All, I am wanting to make a plot with a secondary y axis, just like the matlab function plotyy does. Does anyone have any tips on how to do this with matplotlib? Cheers, Cory. -- --------------------------------------------------- Cory Davis Institute for Atmospheric and Environmental Science Room 307, Crew Building, Kings Buildings, University of Edinburgh. Edinburgh EH9 3JN phone: +44 131 6505092 www: http://www.geos.ed.ac.uk/contacts/homes/cdavis |
|
From: Derrick S. <Der...@no...> - 2005-05-11 19:00:20
|
Jeff,
You're probably right, my numarray.__version__ = 0.9. After updating numarray
to 1.3.1 all the examples ran except randompoints.py. Perhaps you knew this.
After changing line 44 as below...
# r = (m.projtran.rmajor/1000.)*get_dist(lon,lons[0:nob],lat,lats[0:nob])
r = (m.projtran.rsphere/1000.)*get_dist(lon,lons[0:nob],lat,lats[0:nob])
randompoints.py ran to completion. I'm not sure if it was an appropriate
change but at least the example competed. thanks Jeff...
Best,
Derrick
On Wed May 11 2005 01:40 pm, Jeff Whitaker wrote:
> Derrick Snowden wrote:
> > Hi all,
> >
> > I'm new to this product so my question involves installation issues
> > with Basemap. I had no problem installing matplotlib and as far as I
> > could tell, there were no issues preventing the Basemap installation.
> > However, when I run the test scripts I get an error message that seems
> > to be related to cPickle. Several of the example scripts yield the
> > same error, but not all. Any suggestions?
> >
> > The message is included below and the platform I'm using is Fedora
> > core 2 linux. Python version 2.3.3.
> >
> > Thanks for any suggestions,
> > Derrick
> >
> >
> > log of the error messages...
> >
> > /usr/lib/python2.3/site-packages/matplotlib/__init__.py:636:
> > UserWarning: Bad key "verbose.erro" on line 199 in
> > /home/snowden/.matplotlibrc
> > warnings.warn('Bad key "%s" on line %d in %s' % (key, cnt, fname))
> > loaded rc file /home/snowden/.matplotlibrc
> > matplotlib version 0.80
> > verbose.level helpful
> > interactive is False
> > platform is linux2
> > numerix Numeric 23.3
> > font search path ['/usr/share/matplotlib']
> > loaded ttfcache file /home/snowden/.ttffont.cache
> > matplotlib data path /usr/share/matplotlib
> > backend GTKAgg version 2.2.0
> > Traceback (most recent call last):
> > File "plotmap.py", line 11, in ?
> > topodict = cPickle.load(open('etopo20.pickle','rb'))
> > File "/usr/lib/python2.3/site-packages/numarray/generic.py", line
> > 160, in ClassicUnpickler
> > self.__setstate__(state)
> > File "/usr/lib/python2.3/site-packages/numarray/numarraycore.py",
> > line 492, in __setstate__
> > self._type = state["_type"]
> > AttributeError: ("'str' object has no attribute 'name'", <function
> > ClassicUnpickler at 0x40e435a4>, (<class
> > 'numarray.numarraycore.NumArray'>, {'_type': 'Float32', '_itemsize':
> > 4, '_shape': (1081,), '_bytestride': 4, '_byteoffset': 0, '_version':
> > '1.1', '_byteorder': 'big', '_data': <memory at 083f7568 with
> > size:4324 held by object 083f7548 aliasing object 00000000>,
> > '_strides': (4,)}))
>
> Derrick: The example is trying to read a Pickle file with some data. I
> think the problem may be that your numarray is too old. New versions of
> numarray cannot read pickles created by very old versions of numarry,
> apparently. Is your numarray older than 1.0?
>
> -Jeff
--
Derrick Snowden
PhOD/AOML/NOAA
4301 Rickenbacker Causeway
Miami, FL 33149
Office: 305.361.4322 Fax: 305.361.4392
|
|
From: Fernando P. <Fer...@co...> - 2005-05-11 18:19:06
|
Matt Newville wrote: >>Mmh, the problem is that I don't know how to achieve this in a clean, >>distutils-based way. I can't go changing the shebang line by hand, since I >>don't know where things will end up, and as far as I know there is no way to >>force this kind of behavior onto distutils. Do you know any such incantation >>to achieve the desired result? > > > (Sorry for not getting back to you on this -- conference all > last week, still finding emails to answer). I'd guess that for > sys.platform == 'Darwin', you _could_ assume that you know where > things will end up. I'm a bit of a one-trick-pony (linux being my trick, and if that), so I'm afraid I'll have to ask for a bit of feedback from you and/or other OSX real gurus. I worry about polluting setup.py with os-specific hacks (the stuff for win32 is ugly enough), and in OSX there's the issue of the Apple Python vs. the fink one vs. any other hand-installed one. What happens if paths get hardcoded in there, and someone wants to install with some test python version they have living in /scratch/foo/bar/python2.5.0CVS... ? Messing with distutils is a bit dangerous, because people expect that if they issue a certain command with one of the relocation flags (--home, --prefix), it will do the right thing. Are you sure that your idea won't generate conflicts with such options, and across multiple python versions living in the same system? I don't want to sound discouraging, but I am _very_ careful with tweaking the setup scripts. They are really easy to break, so I won't touch them until I am _very_ convinced that the changes are really, really solid and properly take into account all the foreseable pitfalls. And the problem with breaking setup.py, is that you typically find out about it only when some user with a sligthly unusual config comes back complaining about a broken system. I'd like to avoid that if possible. Cheers, f |
|
From: Jeff W. <js...@fa...> - 2005-05-11 17:40:17
|
Derrick Snowden wrote:
> Hi all,
>
> I'm new to this product so my question involves installation issues
> with Basemap. I had no problem installing matplotlib and as far as I
> could tell, there were no issues preventing the Basemap installation.
> However, when I run the test scripts I get an error message that seems
> to be related to cPickle. Several of the example scripts yield the
> same error, but not all. Any suggestions?
>
> The message is included below and the platform I'm using is Fedora
> core 2 linux. Python version 2.3.3.
>
> Thanks for any suggestions,
> Derrick
>
>
> log of the error messages...
>
> /usr/lib/python2.3/site-packages/matplotlib/__init__.py:636:
> UserWarning: Bad key "verbose.erro" on line 199 in
> /home/snowden/.matplotlibrc
> warnings.warn('Bad key "%s" on line %d in %s' % (key, cnt, fname))
> loaded rc file /home/snowden/.matplotlibrc
> matplotlib version 0.80
> verbose.level helpful
> interactive is False
> platform is linux2
> numerix Numeric 23.3
> font search path ['/usr/share/matplotlib']
> loaded ttfcache file /home/snowden/.ttffont.cache
> matplotlib data path /usr/share/matplotlib
> backend GTKAgg version 2.2.0
> Traceback (most recent call last):
> File "plotmap.py", line 11, in ?
> topodict = cPickle.load(open('etopo20.pickle','rb'))
> File "/usr/lib/python2.3/site-packages/numarray/generic.py", line
> 160, in ClassicUnpickler
> self.__setstate__(state)
> File "/usr/lib/python2.3/site-packages/numarray/numarraycore.py",
> line 492, in __setstate__
> self._type = state["_type"]
> AttributeError: ("'str' object has no attribute 'name'", <function
> ClassicUnpickler at 0x40e435a4>, (<class
> 'numarray.numarraycore.NumArray'>, {'_type': 'Float32', '_itemsize':
> 4, '_shape': (1081,), '_bytestride': 4, '_byteoffset': 0, '_version':
> '1.1', '_byteorder': 'big', '_data': <memory at 083f7568 with
> size:4324 held by object 083f7548 aliasing object 00000000>,
> '_strides': (4,)}))
>
>
Derrick: The example is trying to read a Pickle file with some data. I
think the problem may be that your numarray is too old. New versions of
numarray cannot read pickles created by very old versions of numarry,
apparently. Is your numarray older than 1.0?
-Jeff
--
Jeffrey S. Whitaker Phone : (303)497-6313
Meteorologist FAX : (303)497-6449
NOAA/OAR/CDC R/CDC1 Email : Jef...@no...
325 Broadway Office : Skaggs Research Cntr 1D-124
Boulder, CO, USA 80303-3328 Web : http://tinyurl.com/5telg
|
|
From: John H. <jdh...@ac...> - 2005-05-11 15:06:14
|
>>>>> "andrea" == andrea gavana <and...@ti...> writes:
andrea> Is there a way to add an histogram to my subplot?
Make sure ax.hold(True) is set, and then call hist after plot
ax.hold(True)
ax.plot(something)
ax.hist(something)
Should work...
JDH
|
|
From: Derrick S. <Der...@no...> - 2005-05-11 14:59:31
|
Hi all,
I'm new to this product so my question involves installation issues with
Basemap. I had no problem installing matplotlib and as far as I could
tell, there were no issues preventing the Basemap installation.
However, when I run the test scripts I get an error message that seems
to be related to cPickle. Several of the example scripts yield the same
error, but not all. Any suggestions?
The message is included below and the platform I'm using is Fedora core
2 linux. Python version 2.3.3.
Thanks for any suggestions,
Derrick
log of the error messages...
/usr/lib/python2.3/site-packages/matplotlib/__init__.py:636:
UserWarning: Bad key "verbose.erro" on line 199 in
/home/snowden/.matplotlibrc
warnings.warn('Bad key "%s" on line %d in %s' % (key, cnt, fname))
loaded rc file /home/snowden/.matplotlibrc
matplotlib version 0.80
verbose.level helpful
interactive is False
platform is linux2
numerix Numeric 23.3
font search path ['/usr/share/matplotlib']
loaded ttfcache file /home/snowden/.ttffont.cache
matplotlib data path /usr/share/matplotlib
backend GTKAgg version 2.2.0
Traceback (most recent call last):
File "plotmap.py", line 11, in ?
topodict = cPickle.load(open('etopo20.pickle','rb'))
File "/usr/lib/python2.3/site-packages/numarray/generic.py", line
160, in ClassicUnpickler
self.__setstate__(state)
File "/usr/lib/python2.3/site-packages/numarray/numarraycore.py",
line 492, in __setstate__
self._type = state["_type"]
AttributeError: ("'str' object has no attribute 'name'", <function
ClassicUnpickler at 0x40e435a4>, (<class
'numarray.numarraycore.NumArray'>, {'_type': 'Float32', '_itemsize': 4,
'_shape': (1081,), '_bytestride': 4, '_byteoffset': 0, '_version':
'1.1', '_byteorder': 'big', '_data': <memory at 083f7568 with size:4324
held by object 083f7548 aliasing object 00000000>, '_strides': (4,)}))
|
|
From: <and...@ti...> - 2005-05-11 14:41:14
|
Hello NG,
as usual, I am using wxPython + MatPlotLib to create nice interfaces
+ nice plots. However, I'm having a problem (probably I am unable to find=
the right code to do it) in putting together 2 plots. This is the situati=
on:
In some way, I have calculated a CDF of a Numeric array, and I can easily=
plot it using the sequence:
self.fig =3D Figure()
self.canvas =3D FigureCanvas(self, -1, self.fig)
axdata =3D self.fig.add_subplot(111)
mp =3D axdata.plot(CDF,ArrayFromZeroToOne,'b-')
Now, I would like to add the histogram of my array to the same figure, bu=
t
I'm getting nowhere. The histogram is not displayed.
Note that I am *not* importing Pylab or similar, I use:
from matplotlib.backends.backend_wxagg import FigureCanvasWxAgg as Figure=
Canvas
from matplotlib.backends.backend_wx import NavigationToolbar2Wx
from matplotlib.figure import Figure
Is there a way to add an histogram to my subplot?
Thank you for every suggestion.
Andrea.
|
|
From: John H. <jdh...@ac...> - 2005-05-11 14:11:11
|
>>>>> "Andrew" == Andrew Dalke <da...@da...> writes:
Andrew> A few weeks ago I asked about using matplotlib to make a
Andrew> simple client-side image map for a web page.
Hmm, I missed this post somehow. Sorry to have ignored you :-( It
looks like you did just fine w/o me
Andrew> I since figured out my problem. I wrote an set of essays
Andrew> on it. The most relevant is at
Andrew> http://www.dalkescientific.com/writings/diary/archive/2005/04/24/
Andrew> interactive_html.html
A friend was just pestering me to add support for this for his
business. Thanks for figuring it out! The articles are very nice;
I'll be sure to link to them from the mpl web site.
A few comments:
Andrew> They can be used together, as you might have seen in my code from last time.
The link
http://www.dalkescientific.com/writings/diary/archive/2005/04/22/matplotlib
associated with the text "my code from last time" is stale.
Andrew> Most image formats are in pixels, and the number of pixels
Andrew> in an inch depends on the screen size, resolution, and even
Andrew> the distance to the screen. The conversion to pixels is done
Andrew> by the print_figure() call, which is why it takes the dpi
Andrew> parameter. Looking at the library code I see that the
Andrew> Figure() constructor also takes a dpi parameter. I don't
Andrew> know when it's used.
It is used when building the GUI window (eg dpi should reflect your
screen dpi). It is not used for hardcopy, because the print_figure
dpi setting overrides it.
Andrew> I can't find any place in matplotlib that gives the final
Andrew> image size in pixels. I think the right place is to have
Andrew> print_figure() return a data structure with information
Andrew> about what it just printed (image size, perhaps the number
Andrew> of bytes). But it doesn't so I'll compute it myself.
A good idea. Could I trouble you to fill out a support request at
http://sourceforge.net/tracker/?group_id=80706&atid=560721 . This is
something that takes more that just a minute to fix because it has to
be done on each backend, so having it on the support requests page
will help prevent us from forgetting to do it.
Thanks for the articles -- they are very helpful.
JDH
|
|
From: John H. <jdh...@ac...> - 2005-05-11 13:54:15
|
>>>>> "Florian" == Florian Lindner <mai...@xg...> writes:
Florian> Hello, which interface is to prefer when using it from
Florian> python scripts? Are they both offer the same
Florian> functionality? Which one is more pythonic? Where can I
Florian> find examples for using the matplotlib classes? (I've
Florian> only found a lot of examples for pylab)
It depends a bit on how you want to use matplotlib. Interactively, eg
from a shell, the pylab interface is more efficient. For generating
scripts in batch mode, eg on a web application server, or for building
a GUI, the matplotlib API is better because it gives you more control
and less magic.
See the FAQ "Is there any guide to using matplotlib with pythonic / OO
/API rather than the pylab interface?" for a few pointers to
resources, which I will soon update with a pointer to Andrew Dalke's
very nice recent article, hot off the presses, "matplotlib without a
GUI" at
http://www.dalkescientific.com/writings/diary/archive/2005/04/23/matplotlib_without_gui.html
JDH
|
|
From: Alan G I. <ai...@am...> - 2005-05-11 13:36:35
|
On Wed, 11 May 2005, Florian Lindner apparently wrote: > which interface is to prefer when using it from python scripts? Are they both > offer the same functionality? Which one is more pythonic? > Where can I find examples for using the matplotlib classes? (I've only found a > lot of examples for pylab) http://matplotlib.sourceforge.net/faq.html#OO hth, Alan Isaac |
|
From: Florian L. <mai...@xg...> - 2005-05-11 12:57:51
|
Hello, which interface is to prefer when using it from python scripts? Are they both offer the same functionality? Which one is more pythonic? Where can I find examples for using the matplotlib classes? (I've only found a lot of examples for pylab) Thanks, Florian |