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
(5) |
2
(24) |
3
(2) |
4
|
5
(4) |
6
(1) |
7
(22) |
8
(9) |
9
(23) |
10
(6) |
11
|
12
(7) |
13
(17) |
14
(12) |
15
(10) |
16
(22) |
17
(11) |
18
(6) |
19
(11) |
20
(13) |
21
(10) |
22
(7) |
23
(7) |
24
(5) |
25
(3) |
26
(20) |
27
(17) |
28
(25) |
29
(16) |
30
(17) |
31
(8) |
set markerfacecolor (a.k.a. mfc) = 'None' (make sure you include the quotes). -Andrew John T Whelan wrote: > Dear matplotlib gurus, > > When I use > > plot(t,x,'rx',t,y,'bs'); > > in matlab, it produces blue boxes for y, i.e., squares with a blue > border and a transparent interior, so that if one of them lies on top > of a red x, I can see the red x inside the blue box. The same > construction in matplotlib produces blue squares: squares with a black > border and a blue interior. I can change the color of the interior > with the markerfacecolor or mfc argument, e.g., > > plot(t,x,'rx'); > plot(t,y,'bs',mec='b',mfc='w'); > > but that produces an opaque white interior which renders invisible any > red x it covers up. > > I can change the transparency of a line with the alpha argument, but > there seems to be no corresponding markerfacealpha. > > Is there a way in matplotlib to get a square marker with a blue border > and a transparent interior? > > Thanks, >
Dear matplotlib gurus, When I use plot(t,x,'rx',t,y,'bs'); in matlab, it produces blue boxes for y, i.e., squares with a blue border and a transparent interior, so that if one of them lies on top of a red x, I can see the red x inside the blue box. The same construction in matplotlib produces blue squares: squares with a black border and a blue interior. I can change the color of the interior with the markerfacecolor or mfc argument, e.g., plot(t,x,'rx'); plot(t,y,'bs',mec='b',mfc='w'); but that produces an opaque white interior which renders invisible any red x it covers up. I can change the transparency of a line with the alpha argument, but there seems to be no corresponding markerfacealpha. Is there a way in matplotlib to get a square marker with a blue border and a transparent interior? Thanks, -- ====================================================================== Office: 0.17 (Golm) Dr. John T. Whelan Phone: +49 331 567 7117 MPI for Gravitational Physics FAX: +49 331 567 7298 (Albert-Einstein Institute) http://www.aei.mpg.de/~whelan/ D-14424 Potsdam joh...@li... joh...@ae... ======================================================================
I guess I didn't read the following carefully: "... The aspect ratio of the figure window is that of the array ... Because of how matshow() tries to set the figure aspect ratio to be the one of the array, ..." which would explain the behaviour below. Why the restrictions? Seems one would want to put colorbars, etc in the same figure and so why not behave like imshow() which it calls to make the output. And why the new figure (so no possibility of subplots or overlays)? Just curious ... I guess I will use imshow() directly and modify the axes as suggested before to get the output looking like matshow() Cheers, Suresh On Thu, 8 Mar 2007, Suresh Pillai wrote: > If one inserts a colorbar after using matshow, then the matrix plot's aspect > ratio is incorrect altered. Here are 2 cases to compare > > import pylab > matrix = pylab.rand(30,30) > > 1) matshow() before colorbar() > > pylab.matshow(matrix) > pylab.colorbar() > pylab.show() > > The matrix plot is squished in the x-direction while not in the y thus losing > its proper aspect ratio (equal by default). > > 2) imshow() before colorbar() > > pylab.imshow(matrix) > pylab.colorbar() > pylab.show() > > Everthing is okay in this case. > > > Thanks, > Suresh > >
We are looking for someone to fill a position at the Space Telescope Science Institute (in Baltimore, MD) to work on Python tools for astronomical data processing and analysis. Details can be found at: http://www.stsci.edu/institute/brc/hr/co/external/Req559.html
I discovered the same problem, so I went looking and found the mailing list properly archived at nabble.com: http://www.nabble.com/Creating-a-non-linear-colormap.-t3362841.html Cheers, Suresh On Fri, 9 Mar 2007, Ken McIvor wrote: > On Mar 9, 2007, at 5:11 AM, Uwe Schmitt wrote: >> >> Thanks, but I can not access this article from the mailing lists >> archive. >> On sourceforge the newest posting is from 23th feb. > > I'm not sure what the problem with SourceForge is. I'll forward you > that email off-list. > > Ken > > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share your > opinions on IT & business topics through brief surveys-and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > Matplotlib-users mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-users >
Thank you, I think thatthis will solve my problem :) I didn't know this class existed. Matthieu 2007年3月9日, John Hunter <jd...@gm...>: > > On 3/9/07, Matthieu Brucher <mat...@gm...> wrote: > > > What I have is a set of points in a numpy.array - for instance size > (2000, > > 2) -. What I have as well is a nump.array of size (2000, 3). How can I > make > > plot understand that each line of the set points must be painted with > the > > corresponding line in the colour array ? > > You'll probably want to use a regular poly collection, as in the > example below. Your array of facecolors can pretty much be whatever > you want: > > from pylab import figure, nx, show, cm > from matplotlib.collections import RegularPolyCollection > > > fig = figure() > ax = fig.add_subplot(111) > > offsets = nx.mlab.rand(20,2) > facecolors = [cm.jet(x) for x in nx.mlab.rand(20)] > black = (0,0,0,1) > > collection = RegularPolyCollection( > fig.dpi, > numsides=5, # a pentagon > rotation=0, > sizes=(50,), > facecolors = facecolors, > edgecolors = (black,), > linewidths = (1,), > offsets = offsets, > transOffset = ax.transData, > ) > > ax.add_collection(collection) > > show() > > > > > > > > > Matthieu > > > > > ------------------------------------------------------------------------- > > Take Surveys. Earn Cash. Influence the Future of IT > > Join SourceForge.net's Techsay panel and you'll get the chance to share > your > > opinions on IT & business topics through brief surveys-and earn cash > > > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > > _______________________________________________ > > Matplotlib-users mailing list > > Mat...@li... > > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > > > > >
On 3/9/07, Matthieu Brucher <mat...@gm...> wrote: > What I have is a set of points in a numpy.array - for instance size (2000, > 2) -. What I have as well is a nump.array of size (2000, 3). How can I make > plot understand that each line of the set points must be painted with the > corresponding line in the colour array ? You'll probably want to use a regular poly collection, as in the example below. Your array of facecolors can pretty much be whatever you want: from pylab import figure, nx, show, cm from matplotlib.collections import RegularPolyCollection fig = figure() ax = fig.add_subplot(111) offsets = nx.mlab.rand(20,2) facecolors = [cm.jet(x) for x in nx.mlab.rand(20)] black = (0,0,0,1) collection = RegularPolyCollection( fig.dpi, numsides=5, # a pentagon rotation=0, sizes=(50,), facecolors = facecolors, edgecolors = (black,), linewidths = (1,), offsets = offsets, transOffset = ax.transData, ) ax.add_collection(collection) show() > Matthieu > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share your > opinions on IT & business topics through brief surveys-and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > Matplotlib-users mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > >
> > Complete examples always help ince we have no way of knowing what the > points data structures look like, but I'll hazard a gues. The x and y > arguments to "plot" need to be sequences. Ie, something like > > plot([0.5], [0.5], 'ro') > > It can be inefficient to plot many separate points this way -- if you > have a lot of points, use a > matplotlib.collections.RegularPolyCollection or scatter. > Thank you for your answer :) OK, I'll try to wrap them :|. The best solution would indeed be to paint them all at once, but I didn't manage to do that, even when I looked in the scatter_demo2 example :( What I have is a set of points in a numpy.array - for instance size (2000, 2) -. What I have as well is a nump.array of size (2000, 3). How can I make plot understand that each line of the set points must be painted with the corresponding line in the colour array ? Matthieu
On 3/9/07, Fernando Perez <fpe...@gm...> wrote: > (or matlab for that matter) in my life, I was rather surprised by the > behavior and (mis)understood it as a bug. > > I've always gotten by just fine in pylab without even knowing what > hold did, and simply clearing the figure by hand when needed or just > making a new one. Just to add a few data points -- the default "hold" state can be set in your rc file. It is a property of the current figure and the current axes. In you example, when you set fold before creating the third figure, the setting applued to the current figure (figure 2) but not the next figure. JDH
On 3/9/07, Uwe Schmitt <usc...@mi...> wrote: > I would like to display an image using pylab > without automatic scaling to the default size of the plot window. > > How can I achieve this ? If you want displayed image to just be a pixel dump of the actual image use figimage http://matplotlib.sf.net/examples/figimage_demo.py JDH
On 3/9/07, Matthieu Brucher <mat...@gm...> wrote: > Hi, > > I'm trying to plot a set of points, each point having a different color. > For the moment, I'm trying to do something like that : > > for indice in range(0, points.shape[0]): > pl.plot(points[indice, 0], points[indice, 1], 'o', c = > colours[indice,:], hold = True) > > where points is a numpy array of point and colours is a numpy array of > dimension (points.shape[0], 3) > > With Matlab, something like this would function, but not in matplotlib, it > tells me : > ValueError: need more than 0 values to unpack Complete examples always help ince we have no way of knowing what the points data structures look like, but I'll hazard a gues. The x and y arguments to "plot" need to be sequences. Ie, something like plot([0.5], [0.5], 'ro') It can be inefficient to plot many separate points this way -- if you have a lot of points, use a matplotlib.collections.RegularPolyCollection or scatter. JDH
On Mar 9, 2007, at 5:11 AM, Uwe Schmitt wrote: > > Thanks, but I can not access this article from the mailing lists > archive. > On sourceforge the newest posting is from 23th feb. I'm not sure what the problem with SourceForge is. I'll forward you that email off-list. Ken
Hi, All Is it possible to draw any graphical primitives in the plot area using its scale? Let say, I want to plot a filled circle there. Where do I have to look on? Thanks in advance, Alexey
Ken McIvor wrote: > Uwe, > > I don't know the answer to your question, but yesterday Rob Hetland > sent out and email entitled "Creating a non-linear colormap." that > includes example code. That might help you get started. > > Ken > Thanks, but I can not access this article from the mailing lists archive. On sourceforge the newest posting is from 23th feb. Greetings, Uwe
Hi, I'm trying to plot a set of points, each point having a different color. For the moment, I'm trying to do something like that : for indice in range(0, points.shape[0]): pl.plot(points[indice, 0], points[indice, 1], 'o', c = colours[indice,:], hold = True) where points is a numpy array of point and colours is a numpy array of dimension (points.shape[0], 3) With Matlab, something like this would function, but not in matplotlib, it tells me : ValueError: need more than 0 values to unpack I am missing something ? Matthieu
Hello, I would like to display an image using pylab without automatic scaling to the default size of the plot window. How can I achieve this ? Greetings, Uwe
Hi Simon, On 3/8/07, Simon Wood <sgw...@gm...> wrote: > On 3/8/07, Fernando Perez <fpe...@gm...> wrote: > > Hi all, > > > > today at work we ran into some odd behavior, all of which seems to be > > triggered by calling hold(). I'm using a fresh SVN build from this > > afternoon. > > > > Here's the first example demonstrating the problem, it's best to run > > this in a fresh pylab shell or from the command line, since I suspect > > internal state matters (when it shouldn't): > > > > import pylab as P > > > > x = P.arange(10) > > y = x+1 > > > > P.figure() > > P.plot(x,label='one') > > P.plot(y,label='two') > > P.legend() > > P.title('Two plots ok') > > > > P.figure() > > P.hold(True) > > P.plot(x,label='one') > > P.plot(y,label='two') > > P.legend() > > P.title('Two plots ok - HOLD called') > > P.hold(False) > > > > P.figure() > > P.plot(x,label='one') > > P.plot(y,label='two') > > P.legend() > > P.title('One plot MISSING!') > > > > P.show() > > > > #### EOF > > > > I do not think this is a bug. The default value for the hold function is > True. When you originally plotted x and y the hold state was already set to > True. So, actually your first case and second case are the same. However, > right before your third figure you set P.hold(False) . You then plot x > followed by y. So, yes I would expect to see only one line in the final > figure. This is exactly like Matlab (perhaps with the exception that the > default state of hold is False in Matlab). Perhaps that is what is confusing > you and your colleague. In Matlab the default state of hold is False, > however in Matplotlib is looks like the default state of hold is True. Many thanks for your clear explanation. Since I had never used hold (or matlab for that matter) in my life, I was rather surprised by the behavior and (mis)understood it as a bug. I've always gotten by just fine in pylab without even knowing what hold did, and simply clearing the figure by hand when needed or just making a new one. Sorry for the noise. Regards, f
On 3/8/07, Fernando Perez <fpe...@gm...> wrote: > > Hi all, > > today at work we ran into some odd behavior, all of which seems to be > triggered by calling hold(). I'm using a fresh SVN build from this > afternoon. > > Here's the first example demonstrating the problem, it's best to run > this in a fresh pylab shell or from the command line, since I suspect > internal state matters (when it shouldn't): > > import pylab as P > > x = P.arange(10) > y = x+1 > > P.figure() > P.plot(x,label='one') > P.plot(y,label='two') > P.legend() > P.title('Two plots ok') > > P.figure() > P.hold(True) > P.plot(x,label='one') > P.plot(y,label='two') > P.legend() > P.title('Two plots ok - HOLD called') > P.hold(False) > > P.figure() > P.plot(x,label='one') > P.plot(y,label='two') > P.legend() > P.title('One plot MISSING!') > > P.show() > > #### EOF > I do not think this is a bug. The default value for the hold function is True. When you originally plotted x and y the hold state was already set to True. So, actually your first case and second case are the same. However, right before your third figure you set P.hold(False) . You then plot x followed by y. So, yes I would expect to see only one line in the final figure. This is exactly like Matlab (perhaps with the exception that the default state of hold is False in Matlab). Perhaps that is what is confusing you and your colleague. In Matlab the default state of hold is False, however in Matplotlib is looks like the default state of hold is True. -Simon
Hi all, today at work we ran into some odd behavior, all of which seems to be triggered by calling hold(). I'm using a fresh SVN build from this afternoon. Here's the first example demonstrating the problem, it's best to run this in a fresh pylab shell or from the command line, since I suspect internal state matters (when it shouldn't): import pylab as P x = P.arange(10) y = x+1 P.figure() P.plot(x,label='one') P.plot(y,label='two') P.legend() P.title('Two plots ok') P.figure() P.hold(True) P.plot(x,label='one') P.plot(y,label='two') P.legend() P.title('Two plots ok - HOLD called') P.hold(False) P.figure() P.plot(x,label='one') P.plot(y,label='two') P.legend() P.title('One plot MISSING!') P.show() #### EOF And here's the second manifestation of the problem, where the colorbar gets all messed up: import numpy as N import pylab as P a = N.random.rand(64,64) P.figure() P.imshow(a) P.colorbar() P.title('Colorbar OK') # If the hold() calls are commented out, the problem disappears P.figure() P.hold(True) P.plot(range(10)) P.hold(False) P.figure() P.imshow(a) P.colorbar() P.title('Colorbar BROKEN!') P.show() #### EOF It looks like making calls to hold() messes up internal state in pylab somehow. I've never used hold() myself before, but my officemate did, coming from matlab, and started seeing bizarre behavior. These are little self-contained examples showing the problem. Cheers, f
Uwe Schmitt wrote: > Hi, > > I would like to plot contours with a nonlinear mapping from values to > color as follows: > > -1 -> red > 0 -> white or green or black > +1 -> red > > How can I achieve this ? See examples/contourf_demo.py. The relevant part is this: # Now make a contour plot with the levels specified, # and with the colormap generated automatically from a list # of colors. levels = [-2, -1.5, -1, -0.5, 0, 0.5, 1, 1.5] CS3 = contourf(X, Y, Z, levels, colors = ('r', 'g', 'b'), origin=origin) Try specifying 4 levels; I think this would do what you want (with black for the middle range, for example): levels = [-1.5, -0.5, 0.5, 1.5] CS = contourf(X, Y, Z, levels, colors=('r', 'k', 'r')) Eric > > Greetings, Uwe > > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share your > opinions on IT & business topics through brief surveys-and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > Matplotlib-users mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-users
John Pye wrote: > Hi Eric > > I tried the new spy function under Windows and it seemed to work OK. A > great leap forward, actually, given the problems I had been seeing. > Merging the spy functions was a good idea (does it work ok for very very > large, very sparse matrices?) I don't know any reason it would not, but I have not tried it. > > Trying it under Ubuntu was less straightforward. I built an RPM (python > setup.py bdist_rpm) then converted it to deb package then installed it. > It complained about my old ~/.matplotlib/matplotlibrc file so I moved it > out of the way. Then I fired up again and it was OK. That sounds like the hard way. I find it easy to build and install directly from source--from svn in my case, but from a tarball should be the same. I install it in /usr/local instead of /usr/ so as to keep the distinction between things installed as packages and custom installations. > > In my new Ubuntu install of matplotlib, sans matplotlibrc, I would like > to switch GUIs to GTKAgg but there doesn't seem to be a > /etc/matplotlibrc file from which to base my configuration. Is this a > fault of my rpm-to-deb process, or something that failed during build? > Is it still possible to run the GTKAgg GUI? Has the config system changed? A system-wide matplotlibrc file should get installed somewhere--try using "locate" to find it. I think a change was made since 0.90 such that yours will be in a different place than mine is now. If it turns out that it got lost in the rpm-to-deb conversion, then look at matplotlibrc.template in the source directory. With a couple of string substitutions you can manually turn that into a valid matplotlibrc file and specify your numerix (numpy, I hope) and backend. You can always put it in your ~/.matplotlib directory, and make local copies in working directories if you want different defaults for a given project. > > Finally, can I suggest that the website be updated with some information > about the new release? I couldn't find any readable information about it > on-line -- had to go to the tarball. I think generally the matplotlib > community would benefit from more frequently updated website. While I'm > at it, maybe I could suggest a matplotlib wiki that gets a bit more > prominance on the homepage and that is *separate* from the scipy one, > since the scipy wiki gives completely mixed messages about what plotting > engine is preferred (chaco.wx and VTK and so on) -- it can't be helping > the matplotlib cause. > http://matplotlib.sourceforge.net/whats_new.html (bit out of date) Thanks for the good suggestions. I agree that there could be improvements--it is just a question of who can find the time and motivation to make them, amid competing pressures. Eric > > Cheers > JP
If one inserts a colorbar after using matshow, then the matrix plot's aspect ratio is incorrect altered. Here are 2 cases to compare import pylab matrix = pylab.rand(30,30) 1) matshow() before colorbar() pylab.matshow(matrix) pylab.colorbar() pylab.show() The matrix plot is squished in the x-direction while not in the y thus losing its proper aspect ratio (equal by default). 2) imshow() before colorbar() pylab.imshow(matrix) pylab.colorbar() pylab.show() Everthing is okay in this case. Thanks, Suresh
Uwe, I don't know the answer to your question, but yesterday Rob Hetland sent out and email entitled "Creating a non-linear colormap." that includes example code. That might help you get started. Ken
Hi, I would like to plot contours with a nonlinear mapping from values to color as follows: -1 -> red 0 -> white or green or black +1 -> red How can I achieve this ? Greetings, Uwe
Hi, I have a problem. The following script crashes: from pylab import * a=arange(1500).reshape(50,30) figure() figimage(a) show() Python says: Traceback (most recent call last): File "crash.py", line 5, in ? figimage(a) File "c:\Python24\lib\site-packages\matplotlib\pylab.py", line 810, in figimage draw_if_interactive() File "c:\Python24\lib\site-packages\matplotlib\backends\backend_tkagg.py", line 59, in draw_if_interactive figManager.show() File "c:\Python24\lib\site-packages\matplotlib\backends\backend_tkagg.py", line 301, in show self.canvas.draw() File "c:\Python24\lib\site-packages\matplotlib\backends\backend_tkagg.py", line 151, in draw FigureCanvasAgg.draw(self) File "c:\Python24\lib\site-packages\matplotlib\backends\backend_agg.py", line 398, in draw self.figure.draw(renderer) File "c:\Python24\lib\site-packages\matplotlib\figure.py", line 515, in draw im.draw(renderer) File "c:\Python24\lib\site-packages\matplotlib\image.py", line 473, in draw renderer.draw_image(self.ox, self.oy, im, self.origin, self.figure.bbox) IndexError: Unexpected SeqBase<T> length. This application has requested the Runtime to terminate it in an unusual way. Please contact the application's support team for more information. As you can see, I'm using Python 2.4. Matplotlib is from the Enthought Python Edition, version number is 0.87.2. I tried Google, but looking for "Unexpected SeqBase matplotlib" did not help me. Any hints ? Greetings, Uwe