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
|
|
From: John H. <jdh...@ac...> - 2004-05-08 13:09:56
|
>>>>> "Steve" == Steve Chaplin <ste...@ya...> writes:
Steve> John, I've just started using the new tick locating,
Steve> formatting and date plotting and noticed if you want to
Steve> show day of month, month and year its quite easy to end up
Steve> with major and minor tick labels overwriting each other.
Steve> Is there a way to draw the major tick label underneath the
Steve> minor tick label so they're not competing for the same
Steve> space?
There are a few ways to go here. First of all, with no change to the
code, you can set the tick positions of the minor tick labels as
follow. I'm just winging this code so apologies if there is a minor
mistake somewhere
ax = subplot(111)
#your plot here
for tick in ax.xaxis.get_minor_ticks():
tick.label1.set_y(-0.1)
Note that the y coord of the x tick label is in axes coordinates,
where 0 is the bottom and 1 is the top of the axes, so -0.1 is 10%
below the bottom of the axes. label1 and label2 are the bottom and
top label text.Text instances (this is a recent feature to support
left/right labeling or top/bottom tick labeling) so you can call any
of the Text methods on them.
Note this code only affects the current ticks, so if you were doing
interactive navigation and zoomed out, thereby creating new minor
ticks, the new minor ticks would have their default locations (but I
can fix this fairly easily by updating the copy properties function
that transfers old tick properties to new ones when ticks are created
during interaction).
There is an additional consideration. Currently, the tick drawing
code will skip a minor tick if a major tick has already been drawn at
that exact location. In axis.py there is a line in the axis drawing
code that reads
if seen.has_key(loc): continue
where seen is a dict that has a key if the tick location loc was drawn
by the major tick drawing code. We could add an attribute, something
like forceDraw, to the tick and modify this code so that you could do
if not tick.forceDraw and seen.has_key(loc): continue
and in your code
for tick in ax.xaxis.get_minor_ticks():
tick.forceDraw = True
tick.label1.set_y(-0.1)
Let me know how this works for you.
We could automate this a bit if you think it's worthwhile, eg by
setting a 'draw under' flag for the minor ticks, getting the bounding
boxes of the major ticks in the axis drawing code, and setting the
offsets automagically. This would have the dual advantages of working
in the presence of changes in font size, interaction, etc. The
question is whether it's sufficiently common to justify the extra work
or if the manual control approach above suffices. If you want to add
this feature, I can get you some additional pointers to code showing
how to get the bounding box of all the major tick labels and using
this to control the positioning of the minor tick labels.
JDH
|
|
From: Steve C. <ste...@ya...> - 2004-05-08 04:42:37
|
John, I've just started using the new tick locating, formatting and date plotting and noticed if you want to show day of month, month and year its quite easy to end up with major and minor tick labels overwriting each other. Is there a way to draw the major tick label underneath the minor tick label so they're not competing for the same space? Something like this: Minor label (day of month) 3 10 18 24 31 7 14 22 28 6 13 20 27 Major label (month, year) Jan 2000 Feb 2000 Mar 2000 Regards, Steve |
|
From: John H. <jdh...@ac...> - 2004-05-07 14:39:40
|
>>>>> "Gary" == Gary Ruben <ga...@em...> writes:
Gary> To John Hunter, John, I think this may be quite a common
Gary> wish. I usually want my errorbars to have different
Gary> properties to the default; not just colour but also a
Gary> different weight from the main trend line. Perhaps this is a
Gary> good candidate for factoring into the .matplotlibrc file and
Gary> maybe for extra format specifiers in the errorbar call. I'd
Gary> rate it an extremely low priority though, since you can
Gary> already achieve it as in the example. Alternatively, adding
Gary> this to a code sample could be useful to others. regards,
Gary> Gary
I think making this an rc setting is overkill because it is so
narrowly focused. I also don't think we need to do a full blown
format string (who wants dash dot error bars?).
A color arg would clearly be useful. As for line weights and other
props, I can't think of an elegant way to do it in the errorbar
signature because of the existence of the main line and the error
lines. You *could* do
errorbar(blah, blah,
lineprops = {'color' : 'r', 'linewidth' : 1},
errprops = {'color' : 'k', 'linewidth' : 2})
but I don't think this is any easier, clearer or cleaner than just
doing
line, errlines = errorbar(blah, blah)
set(line, 'color', 'r', 'linewidth', 1)
set(errlines, 'color', 'k', 'linewidth', 2)
So I think an errcolor arg and example showing how to customize the
errorline properties from the lines returned by errorbar is the right
compromise. Are you volunteering :-)?
JDH
|
|
From: Gary R. <ga...@em...> - 2004-05-07 14:16:56
|
To John Hunter,
John, I think this may be quite a common wish. I usually want my errorbars to have different properties to the default; not just colour but also a different weight from the main trend line. Perhaps this is a good candidate for factoring into the .matplotlibrc file and maybe for extra format specifiers in the errorbar call. I'd rate it an extremely low priority though, since you can already achieve it as in the example. Alternatively, adding this to a code sample could be useful to others.
regards,
Gary
----- Original Message -----
From: "Gary Ruben" <ga...@em...>
Date: Fri, 07 May 2004 21:11:10 +1000
To: "Nino Cucchiara" <cuc...@me...>,mat...@li...
Subject: Re: [Matplotlib-users] add errorbars color
> > I've some data with yerrorbars. I want to know if there is one option to
> > add color errorbar, because the fmt flag change only the color of the
> > data points.
>
> Try this example, Nino:
>
> from matplotlib.matlab import *
>
> t = arange(0.1, 4, 0.1)
> s = exp(-t)
> e = 0.1*abs(randn(len(s)))
> figure(1)
> line0, errlines0 = errorbar(t, s, e, fmt='bx:')
> set(errlines0, 'color', 'c')
> line1, errlines1 = errorbar(t, s+1, e, fmt='r-')
> set(errlines1, 'color', 'g')
> xlabel('Distance (m)')
> ylabel('Height (m)')
> title('Mean and standard error as a function of distance')
> legend((line0, line1), ('legend 1', 'legend 2'))
> show()
>
--
___________________________________________________________
Sign-up for Ads Free at Mail.com
http://promo.mail.com/adsfreejump.htm
|
|
From: John H. <jdh...@ac...> - 2004-05-07 14:04:05
|
>>>>> "Kuzminski," == Kuzminski, Stefan R <SKu...@fa...> writes:
Kuzminski> I'm trying to install 0.53.1 on solaris and am getting
Kuzminski> this compile error. Looks like it needs the file
Kuzminski> ft2build.h, but I don't see it anywhere..
You need to make sure a recent version of freetype (we recommend 2.1.7
or later) is installed on your system (and zlib and png for that
matter). If it is installed, you need to make sure you add the base
install dir to your basedir list in setupext.py. Eg if it is
installed to /some/dir/freetype2 you need to add /some/dir to
basedir['sunos5'] in that file; (I'm assuming sys.platform returns
'sunos5').
Where do the GNU tools for solaris go by default; something like
/freeware? I'm referring to the collection from
http://wwws.sun.com/software/solaris/freeware/download.html. I can't
recall but whatever the base install dir is, we should add this dir to
the default sunos5 basedir list.
Finally, please submit back the required changes you made to
seteupext.py (if any) so we can fix this.
Hell, you got gdmodule compiled on win32; matplotlib on solaris should
be a cake walk :-)
Thanks,
John Hunter
|
|
From: Kuzminski, S. R <SKu...@fa...> - 2004-05-07 13:15:24
|
I'm trying to install 0.53.1 on solaris and am getting this compile error. Looks like it needs the file ft2build.h, but I don't see it anywhere.. =20 =20 $ python setup.py build ... In file included from src/_backend_agg.cpp:3: src/ft2font.h:7:22: ft2build.h: No such file or directory <--------missing file error here src/ft2font.h:8:10: #include expects "FILENAME" or <FILENAME> src/ft2font.h:9:10: #include expects "FILENAME" or <FILENAME> src/ft2font.h:10:10: #include expects "FILENAME" or <FILENAME> In file included from src/_backend_agg.cpp:3: src/ft2font.h:29: 'FT_Face' is used as a type, but is not defined as a type. src/ft2font.h:31: 'FT_Matrix' is used as a type, but is not defined as a type. src/ft2font.h:32: 'FT_Vector' is used as a type, but is not defined as a type. src/ft2font.h:33: 'FT_Error' is used as a type, but is not defined as a type. src/ft2font.h:34: parse error before `[' token src/ft2font.h:35: parse error before `[' token error: command 'gcc' failed with exit status 1 bash-2.03$ =20 =20 thanks, Stefan |
|
From: Gary R. <ga...@em...> - 2004-05-07 11:14:48
|
> I've some data with yerrorbars. I want to know if there is one option to
> add color errorbar, because the fmt flag change only the color of the
> data points.
Try this example, Nino:
from matplotlib.matlab import *
t = arange(0.1, 4, 0.1)
s = exp(-t)
e = 0.1*abs(randn(len(s)))
figure(1)
line0, errlines0 = errorbar(t, s, e, fmt='bx:')
set(errlines0, 'color', 'c')
line1, errlines1 = errorbar(t, s+1, e, fmt='r-')
set(errlines1, 'color', 'g')
xlabel('Distance (m)')
ylabel('Height (m)')
title('Mean and standard error as a function of distance')
legend((line0, line1), ('legend 1', 'legend 2'))
show()
--
___________________________________________________________
Sign-up for Ads Free at Mail.com
http://promo.mail.com/adsfreejump.htm
|
|
From: Nino C. <cuc...@me...> - 2004-05-07 10:38:56
|
I've some data with yerrorbars. I want to know if there is one option to add color errorbar, because the fmt flag change only the color of the data points. Thanks. best regards Antonino Cucchiara Brera Observatory Milan, Italy |
|
From: Fernando P. <fp...@co...> - 2004-05-07 04:20:03
|
Travis Oliphant wrote: > Todd Pitts from Sandia asked me the following question. >>all. Most, (emacs included) don't work with any plotting package. I >>have tried gist from scipy and matplotlib (doesn't work with anything >>except straight scripting). Sorry for the 2nd post. I forgot to mention plotting: ipython includes enhanced support for Gnuplot, with modifications to the interactive plotting syntax to make it as quick and easy to use as possible. I use python 100% of the time I'm working on scientific code and data exploration, and my environment is: Xemacs for heavy editing, a terminal with ipython for interactive work, Gnuplot (with ipython's extensions) for 2d plotting and Mayavi (http://mayavi.sourceforge.net) for sophisticated data visualization. With Gnuplot 4.0's mouse support, it is an extremely convenient tool for fast data exploration, capable of publication-quality PostScript output. Finally, for diagram generation and other problems of a graphical but not purely 'plotting' nature, I have been very happy with PyX. IPython was designed _specifically_ to make interactive scientific computing work as fluid as possible. It has direct access to the underlying system shell, it remembers previous values (like Mathematica's %N variables), and has many other features which you may find useful in this kind of context. I haven't looked at matplotlib yet (I've been using gnuplot since the days of Windows 3.0), but I will very soon, and I have heard excellent things about it. For those already familiar with matlab's syntax, this may be a better option than gnuplot. If there are any problems with ipython's interaction with matplotlib, I'll gladly fix them if possible. Regards, Fernando. |
|
From: Fernando P. <fp...@co...> - 2004-05-07 04:09:19
|
Travis Oliphant wrote: > Todd Pitts from Sandia asked me the following question. > > >>I have one final question about python on windows. It seems >>that the non-interactive scripting works well enough. However, I have >>not found a single interactive interpreter that I could recommend to >>members of my group without serious reservations. >> >>I have tried IPython, >>PyCrust (various), IDLE, Using it from within emacs (not cygwin emacs, >>just emacs under windows), PythonWin, etc. They all have serious >>problems when it comes to usability. Most don't have tab completion at >>all. Most, (emacs included) don't work with any plotting package. I >>have tried gist from scipy and matplotlib (doesn't work with anything >>except straight scripting). >> >>Is python really this unusable for >>interactive data exploration and modeling under Windows? As the ipython (http://ipython.scipy.org) author I'm obviously biased, but Windows users seem fairly happy with it. Using Gary Bishop's extensions, it is possible (it should basically work out of the box, though I don't know because I don't use Windows) to get readline and coloring support under a normal (non-cygwin) command shell. Gary's tools are at: http://sourceforge.net/projects/uncpythontools I also imagine that using ipython within emacs as your python shell (which requires a special python-mode.el and ipython.el, available at http://ipython.scipy.org/dist/ipython-emacs-0.3.tgz) must be an option under Windows. I've only used them under Linux, but since this is just regular Emacs lisp, I imagine it should be platform-independent. I hope this helps. Regards, Fernando. |
|
From: John H. <jdh...@ac...> - 2004-05-07 02:18:46
|
>>>>> "Travis" == Travis Oliphant <oli...@ee...> writes:
>> (emacs included) don't work with any plotting package. I have
>> tried gist from scipy and matplotlib (doesn't work with
>> anything except straight scripting). Is python really this
>> unusable for interactive data exploration and modeling under
>> Windows?
Travis> I'm forwarding it to these lists so that individuals with
Travis> more experience on Windows than I have can respond to his
Travis> request. What do people use on Windows for interactive
Travis> work????
Have you tried matplotlib with the TkAgg backend using the standard
python shell, ipython or idle launched with -n? Most people report
good luck on windows with one of these shells for interactive use,
particularly the first two. The TkAgg backend is a fairly recent
addition, and a couple of settings in the matplotlib rc file will make
your experience a little more pleasant
backend : TkAgg
interactive : True
tk.window_focus : True # Maintain shell focus for TkAgg
Now when you fire up python or ipython and then import matplotlib,
you'll be in interactive mode using the Tkinter backend. The window
focus setting is designed to keep your figure from taking the focus
when you issue plotting commands.
Admittedly scripting is the primary way most people use matplotlib,
but we've been working to make the interactive experience better. So
if it's been a while since you tried it interactively on win32, it may
be worth a second look using a recent release. It is important to
consult the backends section of the web page to make sure your IDE is
compatible with the backend you are using, however. Finally, Todd
Miller, who developed the Tk backend, has been very responsive in
fixing known problems, so if you'll let us know what limitations you
find we'll do what we can to fix them up.
John Hunter
|
|
From: Darren D. <dd...@co...> - 2004-05-07 02:04:44
|
=2D----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On Thursday 06 May 2004 09:13 pm, Travis Oliphant wrote: > Todd Pitts from Sandia asked me the following question. > > >I have one final question about python on windows. It seems > >that the non-interactive scripting works well enough. However, I have > >not found a single interactive interpreter that I could recommend to > >members of my group without serious reservations. > > > >I have tried IPython, > >PyCrust (various), IDLE, Using it from within emacs (not cygwin emacs, > >just emacs under windows), PythonWin, etc. They all have serious > >problems when it comes to usability. Most don't have tab completion at > >all. Most, (emacs included) don't work with any plotting package. I > >have tried gist from scipy and matplotlib (doesn't work with anything > >except straight scripting). > > > >Is python really this unusable for > >interactive data exploration and modeling under Windows? > > I'm forwarding it to these lists so that individuals with more > experience on Windows than I have can respond to his request. > > What do people use on Windows for interactive work???? > > -Travis Oliphant > I am new to Python, and have encountered some of these issues. Recently, th= e=20 matplotlib list has had some discussion about interactive use. Others will= =20 have better informed responses than I, but you should know that matplotlib= =20 can be used with an interactive interpreter. If you are still interested (a= nd=20 I encourage you to look into it) check the matplotlib website for more=20 information about interactive use. I recently discovered SciTE/Scintilla, which is a code editor and is capabl= e=20 of generating an API for python based on what modules are installed on your= =20 system. There is a native version of SciTE for windows, and my initial=20 impression has been very good. The matplotlib module was recognized and onc= e=20 the was generated (by running a python script), autocompletion is active. =2D----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.3 (GNU/Linux) iD8DBQFAmu6m9JwfaKJzLVcRAgUjAKDRpXQZlogJs5m3RJksYZSnVDoIOQCgi3Gt =463aEiBdMmhc4Igq+Zz3xBRc=3D =3Dj0hN =2D----END PGP SIGNATURE----- |
|
From: Travis O. <oli...@ee...> - 2004-05-07 01:14:01
|
Todd Pitts from Sandia asked me the following question. >I have one final question about python on windows. It seems >that the non-interactive scripting works well enough. However, I have >not found a single interactive interpreter that I could recommend to >members of my group without serious reservations. > >I have tried IPython, >PyCrust (various), IDLE, Using it from within emacs (not cygwin emacs, >just emacs under windows), PythonWin, etc. They all have serious >problems when it comes to usability. Most don't have tab completion at >all. Most, (emacs included) don't work with any plotting package. I >have tried gist from scipy and matplotlib (doesn't work with anything >except straight scripting). > >Is python really this unusable for >interactive data exploration and modeling under Windows? > I'm forwarding it to these lists so that individuals with more experience on Windows than I have can respond to his request. What do people use on Windows for interactive work???? -Travis Oliphant |
|
From: John H. <jdh...@ac...> - 2004-05-06 15:45:48
|
>>>>> "Alex" == Alex Rada <ale...@ya...> writes:
>> src/_gtkagg.cpp:32: error: `GDK_DRAWABLE' undeclared (first use
Hi Alex, could you provide your platform information, python version
and pygtk version. The latter is obtained by
> pkg-config --modversion pygtk-2.0
The gtk backend requires pygtk 1.99.16 or later, which *may* be the
src of your troubles.
You might also include the gcc commands that are generated in building
gtkagg since I might get some information from the include and library
flags.
John Hunter
|
|
From: Alex R. <ale...@ya...> - 2004-05-06 15:05:45
|
Hi, I have a problem trying to install matplotlib 0.53.1. The error is the following: -------------------------------------------------------------------------------------------------------------- > src/_gtkagg.cpp: In function `PyObject* _agg_to_gtk_drawable(PyObject*, PyObject*)': > src/_gtkagg.cpp:32: error: `GDK_DRAWABLE' undeclared (first use this function) > src/_gtkagg.cpp:32: error: (Each undeclared identifier is reported only once for each function it appears in.) > error: command 'gcc' failed with exit status 1 -------------------------------------------------------------------------------------------------------------- maybe it's due to some library incompatibilties, I hope you can help me. Thanks in advance, Alex |
|
From: John H. <jdh...@ac...> - 2004-05-06 12:23:08
|
>>>>> "Andrew" == Andrew Straw <str...@as...> writes:
Andrew> The same trick should (hopefully) get 0.53.1 to work: get
Andrew> rid of the old matplotlib in site-packages before
Andrew> installing a new one. Probably some files from 0.52 are
Andrew> screwing up 0.53.1.
Andrew> (This is a limitation of Python's distutils -- upgrades
Andrew> should really wipe the package out of site-packages rather
Andrew> than adding files.)
I did some testing by successively installing 0.53.1 and then my CVS
tree comparing a file in site-packages/matplotlib that I knew had
changed in the two versions. New files do indeed replace old files,
but it appears only if their time stamps are newer.
So if I install the 0.53.1 tree to a clean site-packages and then the
CVS tree, the file (mathtext.py) is updated (both dirs have clean
build directories). If I then go back the 0.53.1 and flush the build
dir and reinstall, the *.so files are installed to site-packages
(these are freshly built and so have new time stamps), but the *.py
files are not, presumably because they are older than the ones in
site-packages.
I don't know why you encountered trouble Jim because you were
upgrading in the right direction (screwy system clock, something about
how and when you unarchived the different versions?) but this
definitely explains why your attempt to downgrade failed.
But Andrew is definitely right: when in doubt I do
> sudo rm -rf /usr/local/lib/python2.3/site-packages/matplotlib
> sudo rm -rf build
before installing.
I checked distutils and there does not seem to be any flag you can set
to guarantee a clean install.
JDH
|
|
From: Jim B. <jb...@se...> - 2004-05-06 06:05:22
|
On Wed, 5 May 2004, Andrew Straw wrote: > Jim Benson wrote: > > > <>I finally tried to upgrade from matplotlib-0.52 to 0.53.1. > > > <>ok..so i went into floyd:/usr/local/lib/python2.3/site-packages> > > and moved the matplotlib dir to matplotlib.bak and then tried > > a re-install of 0.52...my app again words..whew! (is there an > > easier way to uninstall?) > > The same trick should (hopefully) get 0.53.1 to work: get rid of the old > matplotlib in site-packages before installing a new one. Probably some > files from 0.52 are screwing up 0.53.1. > > (This is a limitation of Python's distutils -- upgrades should really > wipe the package out of site-packages rather than adding files.) > > Cheers! > Andrew > ...and also a limitation of my late night thinking. Your suggestion appears to have worked like a charm. I'll definitely use your advice for all future upgrades of any python packages. Thanks!! Jim |
|
From: Andrew S. <str...@as...> - 2004-05-06 05:43:09
|
Jim Benson wrote: > <>I finally tried to upgrade from matplotlib-0.52 to 0.53.1. > <>ok..so i went into floyd:/usr/local/lib/python2.3/site-packages> > and moved the matplotlib dir to matplotlib.bak and then tried > a re-install of 0.52...my app again words..whew! (is there an > easier way to uninstall?) The same trick should (hopefully) get 0.53.1 to work: get rid of the old matplotlib in site-packages before installing a new one. Probably some files from 0.52 are screwing up 0.53.1. (This is a limitation of Python's distutils -- upgrades should really wipe the package out of site-packages rather than adding files.) Cheers! Andrew |
|
From: Jim B. <jb...@se...> - 2004-05-06 04:35:12
|
Hi,
I finally tried to upgrade from matplotlib-0.52 to 0.53.1.
When i try to run my app that works fine on 0.52,
it crashes when i try to make plot (the matplotlib part).
floyd:/home/jbenson/python>python nrpapp.py
Traceback (most recent call last):
File
"/usr/local/lib/python2.3/site-packages/matplotlib/backends/backend_wx.py",
line 990, in _onPaint
self.draw()
File
"/usr/local/lib/python2.3/site-packages/matplotlib/backends/backend_wx.py",
line 875, in draw
self.figure.draw(renderer)
File "/usr/local/lib/python2.3/site-packages/matplotlib/artist.py", line
88, in draw
self._draw(renderer, *args, **kwargs)
File "/usr/local/lib/python2.3/site-packages/matplotlib/figure.py", line
89, in _draw
for a in self.axes: a.draw(renderer)
File "/usr/local/lib/python2.3/site-packages/matplotlib/artist.py", line
88, in draw
self._draw(renderer, *args, **kwargs)
File "/usr/local/lib/python2.3/site-packages/matplotlib/axes.py", line
561, in _draw
self.xaxis.draw(renderer)
File "/usr/local/lib/python2.3/site-packages/matplotlib/artist.py", line
88, in draw
self._draw(renderer, *args, **kwargs)
File "/usr/local/lib/python2.3/site-packages/matplotlib/axis.py", line
443, in _draw
tick.draw(renderer)
File "/usr/local/lib/python2.3/site-packages/matplotlib/artist.py", line
88, in draw
self._draw(renderer, *args, **kwargs)
File "/usr/local/lib/python2.3/site-packages/matplotlib/axis.py", line
119, in _draw
if self.label1On: self.label1.draw(renderer)
File "/usr/local/lib/python2.3/site-packages/matplotlib/artist.py", line
88, in draw
self._draw(renderer, *args, **kwargs)
File "/usr/local/lib/python2.3/site-packages/matplotlib/text.py", line
74, in _draw
renderer.draw_text(gc, x, y, self)
File
"/usr/local/lib/python2.3/site-packages/matplotlib/backends/backend_wx.py",
line 499, in draw_text
font = self.get_wx_font(t)
File
"/usr/local/lib/python2.3/site-packages/matplotlib/backends/backend_wx.py",
line 600, in get_wx_font
self.fontweights[t.get_fontweight()], # Weight
KeyError: 'medium'
floyd:/home/jbenson/python>
This may not be enough info for you to help me,
but on the other hand you might immediately see something
that i have wrong. ...err is there the equivalent of
a 'make clean" in the "python setup.py install"
(yup i'm a newbie to some aspects of python)
...i just tried a re-install of 0.52..and
while it did stuff, clearly 0.53 is still being used.
It's my home machine...so not a real big deal.
I also tried:
[root@floyd matplotlib-0.52]# python setup.py clean
running clean
[root@floyd matplotlib-0.52]# python setup.py install
running install
running build
running build_py
running build_scripts
running install_lib
running install_scripts
changing mode of /usr/local/bin/postinstall.py to 755
running install_data
[root@floyd matplotlib-0.52]#
and
[root@floyd matplotlib-0.53.1]# python setup.py clean
running clean
removing 'build/temp.linux-i686-2.3' (and everything under it)
[root@floyd matplotlib-0.53.1]#
and then:
[root@floyd matplotlib-0.52]# python setup.py install
running install
running build
running build_py
running build_scripts
running install_lib
running install_scripts
changing mode of /usr/local/bin/postinstall.py to 755
running install_data
[root@floyd matplotlib-0.52]#
I also tried moving the 0.52 dist to a back, untarring and then
redoing the "python setup.py install"
...but still i'm stuck with my non-working upgrade.
ok..so i went into floyd:/usr/local/lib/python2.3/site-packages>
and moved the matplotlib dir to matplotlib.bak and then tried
a re-install of 0.52...my app again words..whew! (is there an
easier way to uninstall?)
Thanks for any comments (including RT_Fine_M section xx),
Jim
|
|
From: Sajec, M. T. <ms...@tq...> - 2004-05-05 18:13:22
|
>>>>> From: John Hunter [SMTP:jdh...@ac...]
JDH,> This is something I haven't seen before.
JDH,> What platform are you on: windows, linux, os x?
Windows (NT4.0 and 2000)
JDH,> I recommend the following
JDH,> * make sure your hard drive isn't full
JDH,> * open up a shell and change into a directory you
have write
JDH,> permission to and make sure you can write a file to
that dir
JDH,> * create the following test script
JDH,> from matplotlib.matlab import *
JDH,> plot([1,2,3])
JDH,> savefig('testfig')
JDH,> * run this from the shell with
JDH,> python testscript.py -dAgg
JDH,> * see if the file testfig.png is created
This works fine. The Agg backend work fine for me.
JDH,> *see if the file testfig.png is created if so,
JDH,> figure out what is different about what you are
doing....
I've been using the WXAgg backend interactively from a WX based
shell. So, basically I do the following:
1) plot([1,2,3]) and the plot appears
2) click the save icon on the displayed
3) save as "v53WXAggPlot.jpg"
4) No file is saved.... No errors given.
I've also tried replacing steps 2-3 with:
savefig(d:\v53WXAggPlot.jpg"), but had the same results
So, decided to try idle -n with the TkAgg backend (interactive mode
= On).
1) plot([1,2,3]), and the plot appears
3) click the save icon on the displayed plot
4) saved as "v53TkAggPlot.png"
5) It saved!
I've also tried replacing steps 3-4 with:
savefig("d:\v53TkAggPlot2.jpg"), and it saved too!
So, finally I decided to go back to matplotlib 0.51 using a wx based
shell w/the WX backend with interactive mode Off ( interactive wouldn't work
for me in V0.51).
1) plot([1,2,3])
2) show() and the plot appears
3) click the save icon on the displayed plot
4) saved as "v51WXPlot.jpg"
5) It saved!
Could this be an issue isolated to the WXAgg backend in V0.51-3?
Mike
|
|
From: Gary R. <ga...@em...> - 2004-05-05 07:29:07
|
John, Once again you've amazed me with your responsiveness to feature ideas. Thanks! Hopefully I'll get sick of my more pressing work soon and have a look at implememnting some other markers, Gary ----- Original Message ----- From: John Hunter <jdh...@ac...> Date: Tue, 04 May 2004 09:03:22 -0500 To: "Gary Ruben" <ga...@em...> Subject: Re: [Matplotlib-users] matplotlib priorities > >>>>> "Gary" == Gary Ruben <ga...@em...> writes: > > Gary> Hi John, I think it would be nice to have a few more line > Gary> and marker types. For example, DISLIN has 24 marker symbol > Gary> types and 8 line types. Perhaps one could specify (perhaps > Gary> in points) the length of the dashes and the spacing between > Gary> them for dashed line types and perhaps even specify the > Gary> pattern of dashes, dots and spaces, but maybe I'm a line > Gary> type control-freak. > > Rightfully so. Ideally everything should be under your control. BTW, > new symbols are fairly easy to add. Just take a look at lines.py. > Basically, you just have to define one new function following the lead > of the many that are already there and one new dictionary entry in > lineMarkers. If you or anyone else defines some custom markers, > please send them my way. > > Gary> Actually, what I'd really like is for the ratio of dashes to > Gary> the breaks between them to be changed. A 3 or 4 to 1 ratio > Gary> looks nicer than what I'm seeing with GTKAgg (about 1 to 1), > Gary> but others' opinions may vary, hence the control-freak > Gary> suggestion. Gary > > Actually this is how dashes are implemented at the renderer level, > with an arbitrary sequence of on off ink in points. All that was > needed was to expose this to the user interface, which I've done with > a new method set_dashes, eg, > > line.set_dashes([5,3,1,12]) # 5 on 3 off 1 on 12 off > > In the next release there will be a new examples/dash_control.py which > illustrates this. > > Thanks for the suggestion, > John -- ___________________________________________________________ Sign-up for Ads Free at Mail.com http://promo.mail.com/adsfreejump.htm |
|
From: Engelsma, D. <D.E...@La...> - 2004-05-04 19:54:14
|
John --
Thanks for the help! Your example cleared up a lot of problems. I'll send
you a screen dump of what I'm doing when it's ready.
Dave Engelsma
Lacks Wheel Trim Systems
> -----Original Message-----
> From: John Hunter [mailto:jdh...@ac...]
> Sent: Monday, May 03, 2004 4:52 PM
> To: Engelsma, Dave
> Cc: mat...@li...
> Subject: Re: [Matplotlib-users] wxList and FigureCanvasWx
>
> >>>>> "John" == John Hunter <jdh...@ac...> writes:
>
> John> The example is included below. I'll add it to the examples
> John> dir for people who want to work directly with the Agg canvas
> John> and renderer.
>
> oops, left out a critical line - adding the axes to the figure.
>
> Here is a modified example, which also demonstrates initializing a
> Numeric array from the string and passing the image off to PIL....
>
>
> """
> This is an example that shows you how to work directly with the agg
> figure canvas to create a figure using the pythonic API.
>
> In this example, the contents of the agg canvas are extracted to a
> string, which can in turn be passed off to PIL or put in a numeric
> array
>
>
> """
> #!/usr/bin/env python
> from matplotlib.backends.backend_agg import FigureCanvasAgg
> from matplotlib.figure import Figure
> from matplotlib.axes import Subplot
> from matplotlib.mlab import normpdf
> from matplotlib.numerix import randn
>
> fig = Figure(figsize=(5,4), dpi=100)
> ax = Subplot(fig, 111)
> fig.add_axis(ax)
> canvas = FigureCanvasAgg(fig)
>
> mu, sigma = 100, 15
> x = mu + sigma*randn(10000)
>
> # the histogram of the data
> n, bins, patches = ax.hist(x, 50, normed=1)
>
> # add a 'best fit' line
> y = normpdf( bins, mu, sigma)
> line, = ax.plot(bins, y, 'r--')
> line.set_linewidth(1)
>
> ax.set_xlabel('Smarts')
> ax.set_ylabel('Probability')
> ax.set_title(r'$\rm{Histogram of IQ: }\mu=100, \sigma=15$')
>
> ax.set_xlim( (40, 160))
> ax.set_ylim( (0, 0.03))
>
> canvas.draw()
>
> s = canvas.tostring_rgb() # save this and convert to bitmap as needed
>
> # get the figure dimensions for creating bitmaps or numeric arrays,
> # etc.
> l,b,w,h = fig.bbox.get_bounds()
> w, h = int(w), int(h)
>
> if 0:
> # convert to a Numeric array
> X = fromstring(s, UInt8)
> X.shape = h, w, 3
>
> if 0:
> # pass off to PIL
> import Image
> im = Image.fromstring( "RGB", (w,h), s)
> im.show()
>
|
|
From: James B. <bo...@ll...> - 2004-05-04 16:37:00
|
suggestions: (1) a color bar / scale for the pseudo color / image plots. A graphic mapping of values to colors is pretty standard in such displays. (2) Although map projections are listed last in the 'Plot types' category, it would be good to consider how these will be implemented right now. Map projections are just a particular application of a user coordinate ->display coordinate transformation, and such a transformation capability needs to be at the core of all the plots. They are more handy than one might think. If such a transformation hook is available then the map projections are straightforward using PROJ4 ( http://www.remotesensing.org/proj/ ) code, for example. Actually, the trickiest part of coordinate transformations is positioning the axis labels in a 'nice' way. Astronomers use projections too - the whole sky COBE displays appear to be in a Hammer or Mollweide projection. Jim |
|
From: Perry G. <pe...@st...> - 2004-05-04 14:45:10
|
John Hunter wrote: > > Humufr> There are something I did't see in the list (but perhaps > Humufr> it's possible to do now) and that I think will be useful > Humufr> for astronomer. it's to plot an image with axes in > Humufr> astronomical unit (RA and Dec) > > Humufr> like this function in pgplot: > > Humufr> > http://www.astro.caltech.edu/~tjp/pgplot/subroutines.html#PGTBOX > > Humufr> thanks for this software who are very good, > > The new ticker code was designed to support exactly this kind of > application. The documentation > http://matplotlib.sourceforge.net/matplotlib.ticker.html details this > process. That code defines a lot of preset tick locators and > formatters but was primarily designed to be user extensible. > > Since I'm not an astronomer, I'm probably not the best person to write > this, but it would be fairly easy to subclass > matplotlib.ticker.Locator and matplotlib.ticker.Formatter to provide > exactly this functionality. > We are astronomers and we do intend to write tools to allow this. We haven't done this yet but it is fairly high on our list of things to do. I didn't think that such a specialized thing was needed on the generalized goals. You are welcome to write one if you need it sooner of course. Perry Greenfield |
|
From: John H. <jdh...@ac...> - 2004-05-04 14:39:41
|
>>>>> "Humufr" == Humufr <hu...@ya...> writes:
Humufr> There are something I did't see in the list (but perhaps
Humufr> it's possible to do now) and that I think will be useful
Humufr> for astronomer. it's to plot an image with axes in
Humufr> astronomical unit (RA and Dec)
Humufr> like this function in pgplot:
Humufr> http://www.astro.caltech.edu/~tjp/pgplot/subroutines.html#PGTBOX
Humufr> thanks for this software who are very good,
The new ticker code was designed to support exactly this kind of
application. The documentation
http://matplotlib.sourceforge.net/matplotlib.ticker.html details this
process. That code defines a lot of preset tick locators and
formatters but was primarily designed to be user extensible.
Since I'm not an astronomer, I'm probably not the best person to write
this, but it would be fairly easy to subclass
matplotlib.ticker.Locator and matplotlib.ticker.Formatter to provide
exactly this functionality.
Here is a simple example showing how to use a user defined function to
format the ticks (millions of dollars in this case)
from matplotlib.ticker import FuncFormatter
from matplotlib.matlab import *
x = arange(4)
money = [1.5e5, 2.5e6, 5.5e6, 2.0e7]
def millions(x, pos):
'The two args are the value and tick position'
return '$%1.1fM' % (x*1e-6)
formatter = FuncFormatter(millions)
ax = subplot(111)
ax.yaxis.set_major_formatter(formatter)
bar(x, money)
ax.set_xticks( x + 0.5)
ax.set_xticklabels( ('Bill', 'Fred', 'Mary', 'Sue') )
show()
In you case however, you would probably want to define new classes
that derive from Locator and Formatter (you can follow the example of
the many custom locators and formatters in matplotlib.ticker). If you
do, please send the classes in with an example so I can include them
in the standard distribution. If you don't want to do this, I'm sure
one of the stsci guys will do this since they have expressed interest
in this as well.
JDH
|