Re: [Matplotlib-users] memory leak caused by canvas.draw()

2010-12-10 Thread Ryan May
On Thu, Dec 9, 2010 at 5:00 PM, Russell E. Owen ro...@uw.edu wrote: I explored the memory leak in my strip chart widget some more and found that it is caused by calling canvas.draw(), where canvas is: figure = matplotlib.figure.Figure(figsize=(8, 2), frameon=True) canvas =

Re: [Matplotlib-users] LinearSegmentedColormap, Normalize, and colorbar

2010-12-10 Thread Benjamin Root
On Wed, Dec 8, 2010 at 9:15 PM, Timothy W. Hilton hil...@meteo.psu.eduwrote: Hello, I'm trying to teach myself to create custom colormaps to highlight certain aspects of a dataset I am working with. The script below produces two plots -- the first shows a 4x4 array foo of random floats

Re: [Matplotlib-users] Editing a colorbar

2010-12-10 Thread Benjamin Root
On Thu, Dec 9, 2010 at 9:01 AM, Ian Harry ian.ha...@astro.cf.ac.uk wrote: Hi all, I am having a problem with manipulating colorbars. I want to take the cm.Blues colorbar and edit it so that the lowest end of the colorbar is light blue instead of white, or in other words I want to remove the

Re: [Matplotlib-users] Editing a colorbar

2010-12-10 Thread Ian Harry
Hi Ben, Thanks for the suggestion, unfortunately I get: Traceback (most recent call last): File spin_bank.py, line 43, in ? newBlues = mcolors.LinearSegmentedColormap.from_list(newBlues, cm.Blues._lut[cm.Blues.N/3:-3, :-1], 256) AttributeError: class LinearSegmentedColormap has no

Re: [Matplotlib-users] Editing a colorbar

2010-12-10 Thread Benjamin Root
On Fri, Dec 10, 2010 at 11:00 AM, Ian Harry ian.ha...@astro.cf.ac.ukwrote: Hi Ben, Thanks for the suggestion, unfortunately I get: Traceback (most recent call last): File spin_bank.py, line 43, in ? newBlues = mcolors.LinearSegmentedColormap.from_list(newBlues,

[Matplotlib-users] How to plot a set of line segments

2010-12-10 Thread John Salvatier
I have a set of records with (start, end, value) values. Basically they represent we had this value between these two times. The end of one record is not necessarily the end of another record. I would like to plot a set of line segments with end points (x=start, y= value) and (x=end, y=value),

Re: [Matplotlib-users] How to plot a set of line segments

2010-12-10 Thread Chloe Lewis
You can plot them all individually; e.g. rec = ([1,2,.5], [0.5, 3, 1.1], [5, 7, .2]) for r in rec: pylab.plot( r[:2], [r[2]]*2) On Dec 10, 2010, at 12:13 PM, John Salvatier wrote: I have a set of records with (start, end, value) values. Basically they represent we had this value

Re: [Matplotlib-users] Taylor diagram (mdekauwe)

2010-12-10 Thread Christopher Barker
On 12/10/10 10:00 AM, Virgil Stokes wrote: Thanks for this link. I tried to use this code but could not load Numeric; i.e. import Numeric fails. Where does one get the necessary modules to execute this code? Numeric is quite outdated now. You can probably find it somewhere, but it won't be

Re: [Matplotlib-users] How to plot a set of line segments

2010-12-10 Thread John Salvatier
Ah, yes, I should have added that I have a lot of them, so this seems like improper usage. I found the collections.LineCollection class which sounds like what I want. Thank you for the help, John On Fri, Dec 10, 2010 at 12:34 PM, Chloe Lewis chle...@berkeley.edu wrote: You can plot them all