Re: [Matplotlib-users] Histogram with overlapping bins

2012-10-20 Thread Benjamin Root
On Saturday, October 20, 2012, Damon McDougall wrote: > On Sat, Oct 20, 2012 at 10:25 PM, Steven Boada > > > wrote: > > It'd be cool if we could do something like > > > > bins = [(0.0,0.05,0.1),(0.05,0.1,0.15)...] > > > > Where I have specified the left edge, center and right edge of each > > bin

Re: [Matplotlib-users] Problem saving open symbols in PDF

2012-10-17 Thread Benjamin Root
On Wed, Oct 17, 2012 at 1:08 PM, Damon McDougall wrote: > On Wed, Oct 17, 2012 at 5:56 PM, Gökhan Sever > wrote: > > > > > > On Wed, Oct 17, 2012 at 10:21 AM, Benjamin Root wrote: > >> > >> > >> > >> On Wed, Oct 17, 2012 at

Re: [Matplotlib-users] Problem saving open symbols in PDF

2012-10-17 Thread Benjamin Root
On Wed, Oct 17, 2012 at 12:17 PM, Gökhan Sever wrote: > Thanks Mike, > > Another point I noticed is setting linewidth to 0 (in fill_between > function) isn't working as expected when figure is saved as a PDF file. > > I noticed this while posting a sample script on scipy-users: > > http://atmos.uw

Re: [Matplotlib-users] close a figure after show , when plotting many figures from script- using matplotlib.pyplot.figure

2012-10-16 Thread Benjamin Root
On Tue, Oct 16, 2012 at 11:25 AM, hari jayaram wrote: > Hi > I am a relative newbie to matplotlib. > > I have a python script that handles a dataset that comprises 384 sets of > data. > > At the present moment , I read in a set of data - process it - and the > create a figure using code shown bel

Re: [Matplotlib-users] setupegg.py modifies sys.path?

2012-10-15 Thread Benjamin Root
On Mon, Oct 15, 2012 at 2:11 PM, Damon McDougall wrote: > I tried a `python setupegg.py develop` to diagnose a bug for someone. > Now my mpl git repo has magically appeared at the front of my > sys.path. Since I cleaned out the lib/matplotlib directory, I now get > import errors like "No module na

Re: [Matplotlib-users] Format date tick labels

2012-10-12 Thread Benjamin Root
On Friday, October 12, 2012, Ethan Gutmann wrote: > > On Oct 11, 2012, at 2:58 PM, Benjamin Root wrote: > > > On Thu, Oct 11, 2012 at 4:53 PM, Mark Lawrence > 'breamore...@yahoo.co.uk');> > > wrote: > >> On 11/10/2012 10:55, Damon McDougall w

Re: [Matplotlib-users] xlabels on top, ylabels on right

2012-10-12 Thread Benjamin Root
On Fri, Oct 12, 2012 at 6:12 AM, Andreas Hilboll wrote: > > Hi, me again :) > > > > I'm looking for a way to have the xlabels on the top (instead of bottom), > > and the ylabels on the right (instead of left). I guess I could do > > something with twinx / twiny and just not use the left/bottom ax

Re: [Matplotlib-users] Format date tick labels

2012-10-11 Thread Benjamin Root
On Thu, Oct 11, 2012 at 4:53 PM, Mark Lawrence wrote: > On 11/10/2012 10:55, Damon McDougall wrote: > > On Wed, Oct 10, 2012 at 5:00 PM, Benjamin Root wrote: > >> > >> > >> On Wed, Oct 10, 2012 at 10:55 AM, Mark Lawrence < > breamore...@yahoo.co.uk>

Re: [Matplotlib-users] data grid problem

2012-10-11 Thread Benjamin Root
On Thursday, October 11, 2012, Damon McDougall wrote: > On Wed, Oct 10, 2012 at 3:55 PM, Benjamin Root > > wrote: > > > > > > On Wed, Oct 10, 2012 at 9:40 AM, rand0m > > wrote: > >> > >> Hello, > >> > >> I'm new to matplot

Re: [Matplotlib-users] Format date tick labels

2012-10-10 Thread Benjamin Root
On Wed, Oct 10, 2012 at 10:55 AM, Mark Lawrence wrote: > On 10/10/2012 15:41, Mark Lawrence wrote: > > On 10/10/2012 14:29, Benjamin Root wrote: > >> > >> I know of a few people who have difficulties with matplotlib's datetime > >> handling, but t

Re: [Matplotlib-users] data grid problem

2012-10-10 Thread Benjamin Root
On Wed, Oct 10, 2012 at 9:40 AM, rand0m wrote: > Hello, > > I'm new to matplotlib and I hope you can help me out with my question. > When drawing for example a Rectangle() I have to specify it like the > following: > rect = Rectangle((1, 3), 2, 20, facecolor="#aa") > > Where 2 is the length a

Re: [Matplotlib-users] Format date tick labels

2012-10-10 Thread Benjamin Root
On Mon, Oct 8, 2012 at 12:06 PM, Jianbao Tao wrote: > Thanks, Ben. > > Your fix works when the view interval is greater than 1 minute, but not so > much when the view interval is less than one minute. > > BTW, what I am trying to accomplish is to use matplotlib to plot > time-series data that can

Re: [Matplotlib-users] Corrupted percent signs in labels

2012-10-10 Thread Benjamin Root
On Wed, Oct 10, 2012 at 8:23 AM, Michael Droettboom wrote: > It's a known bug, fixed since 1.1.1. > > https://github.com/matplotlib/matplotlib/issues/1211 > > BTW: If you're running the Debian package, how come the version is a > release candidate? (1.1.1rc2) > > Mike > > Mike, We didn't get th

Re: [Matplotlib-users] Corrupted percent signs in labels

2012-10-09 Thread Benjamin Root
On Tuesday, October 9, 2012, Nikolaus Rath wrote: > Damon McDougall > > > writes: > > On Tue, Oct 9, 2012 at 10:56 PM, Damon McDougall > > > > wrote: > >> On Tue, Oct 9, 2012 at 10:32 PM, Nikolaus Rath < > nikolaus-bth8mxji...@public.gmane.org > wrote: > >>> Hello, > >>> > >>> For some reason, my

Re: [Matplotlib-users] trouble switching off smoothing in imshow()

2012-10-09 Thread Benjamin Root
On Tue, Oct 9, 2012 at 10:11 AM, Anand Sivaramakrishnan wrote: > I ask having trouble getting imshow to plot e.g. a detector image > showing pixels as little rectangular or square uniform color blocks - > imshow seems to want to interpolate or smooth the image. > Using imshow("nearest") still pro

Re: [Matplotlib-users] Format date tick labels

2012-10-08 Thread Benjamin Root
On Sun, Oct 7, 2012 at 6:47 PM, Jianbao Tao wrote: > fig = figure() > tsta = num2epoch(date2num(datetime.datetime.now())) > tarr = tsta + arange(0, 60*60*0.5, 0.1)# half hour, dt = > 0.1 sec > x = np.array(num2date(epoch2num(tarr))) > nt = len(tarr) > y = randn(nt) > > ax = fig.ad

Re: [Matplotlib-users] EMF output: too many values to unpack error

2012-10-05 Thread Benjamin Root
On Fri, Oct 5, 2012 at 10:47 AM, Usjes wrote: > Benjamin Root-2 wrote > > On Fri, Oct 5, 2012 at 6:38 AM, Usjes < > > > oisin_nz@.co > > > > wrote: > > > > Does it fail for the example I originally gave? > > > > from pylab import * >

Re: [Matplotlib-users] EMF output: too many values to unpack error

2012-10-05 Thread Benjamin Root
On Fri, Oct 5, 2012 at 6:38 AM, Usjes wrote: > Benjamin Root-2 wrote > > On Thu, Jun 9, 2011 at 12:40 PM, Klonuo Umom < > > > klonuo@ > > > > wrote: > > > > I set up pull requests to fix this problem, so the v1.0.x-maint branch > and > > th

Re: [Matplotlib-users] Saving animations

2012-10-04 Thread Benjamin Root
Replying back to the mailing list so that others can see your response On Thu, Oct 4, 2012 at 12:53 PM, Andreas Mueller wrote: > Thanks for the quick answer. > I am not on the box but I used master from yesterday, so > 89482b21c8582d49a2ddc2865e472eb404fd07e2

Re: [Matplotlib-users] Saving animations

2012-10-04 Thread Benjamin Root
On Thu, Oct 4, 2012 at 10:02 AM, Andreas Mueller wrote: > Hi everybody. > I have been trying to save some animations I made and I encountered the > problem mentioned > here

Re: [Matplotlib-users] XKCD style graphs?

2012-10-04 Thread Benjamin Root
On Thu, Oct 4, 2012 at 10:41 AM, Jason Grout wrote: > On 10/4/12 9:11 AM, Michael Droettboom wrote: > > Yes -- this would be a great application for the path filtering > > infrastructure that matplotlib has. > > > Is that the same as the path effects features, like > http://matplotlib.org/examples

Re: [Matplotlib-users] XKCD style graphs?

2012-10-04 Thread Benjamin Root
On Thu, Oct 4, 2012 at 10:39 AM, Pierre Haessig wrote: > Le 04/10/2012 16:11, Michael Droettboom a écrit : > > Yes -- this would be a great application for the path filtering > > infrastructure that matplotlib has. > Sounds way cooler than post-processing a raster plot image ! > > I'm not aware of

Re: [Matplotlib-users] XKCD style graphs?

2012-10-04 Thread Benjamin Root
On Thu, Oct 4, 2012 at 10:11 AM, Michael Droettboom wrote: > Yes -- this would be a great application for the path filtering > infrastructure that matplotlib has. > > Mike > > I agree with this idea. However, I don't think the code is set up to allow for user-defined path filters. Maybe an AGG

Re: [Matplotlib-users] Bug when zooming on multiple lines separated by None

2012-10-03 Thread Benjamin Root
On Wed, Oct 3, 2012 at 1:02 PM, Phil Elson wrote: > I don't get this on matplotlib/master (and therefore probably not on > 1.2rc2). > > I'm pretty sure masked array line plotting was fixed at some point this > release cycle (I cannot find the appropriate github issue to link to), so I > suggest t

Re: [Matplotlib-users] Create a figure window without navigation toolbar

2012-10-03 Thread Benjamin Root
On Tue, Oct 2, 2012 at 11:09 PM, Jianbao Tao wrote: > Hi, > > I know one can make a figure window without toolbar by doing > mpl.rcParams['toolbar'] = 'None' > > However, this approach is kind of annoying if one just wants to remove the > toolbar for one figure window and to keep the default beha

Re: [Matplotlib-users] Control the position of a figure window

2012-10-03 Thread Benjamin Root
On Tue, Oct 2, 2012 at 11:38 PM, Jianbao Tao wrote: > Hi, > > Is it possible to specify the position of a figure window when one is > created? This will be a killing feature if one wants to put the figure > window at the right place in the screen automatically. It is annoying if > ones has to dra

Re: [Matplotlib-users] Black and white mode

2012-10-03 Thread Benjamin Root
On Tue, Oct 2, 2012 at 11:37 AM, Tony Yu wrote: > > > On Tue, Oct 2, 2012 at 11:04 AM, Benjamin Root wrote: > >> >> >> On Tue, Oct 2, 2012 at 8:31 AM, William Furnass wrote: >> >>> Did anything ever come of the MPL black and white mode mentioned in

Re: [Matplotlib-users] imlim in ax.imshow

2012-10-02 Thread Benjamin Root
t; > >>> On Tue, Oct 2, 2012 at 5:51 PM, K.-Michael Aye > wrote: > >>>> > >>>> > >>>> On Oct 2, 2012, at 6:33 AM, Damon McDougall < > damon.mcdoug...@gmail.com> wrote: > >>>> > >>>>> On Tue

Re: [Matplotlib-users] How to modify the navigation toolbar easily in a matplotlib figure window?

2012-10-02 Thread Benjamin Root
On Tue, Oct 2, 2012 at 2:34 PM, Eric Firing wrote: > On 2012/10/02 8:08 AM, Jianbao Tao wrote: > > Is it possible to do something like the following to modify the > > navigation toolbar in matplotlib? > > > > 1. Generate a figure window, such as by *fig = figure()* > > 2. Get a reference of the

Re: [Matplotlib-users] Black and white mode

2012-10-02 Thread Benjamin Root
On Tue, Oct 2, 2012 at 8:31 AM, William Furnass wrote: > Did anything ever come of the MPL black and white mode mentioned in > the following? I rarely want to produce colour plots and having an > inbuilt mechanism for cycling through line styles that can be > activated with a keyword argument wo

Re: [Matplotlib-users] imlim in ax.imshow

2012-10-02 Thread Benjamin Root
On Mon, Oct 1, 2012 at 7:20 PM, Michael Aye wrote: > Hi! > > I see that the function ax.imshow takes the parameter 'imlim' but in > the source (status: EPD 7.3-2) it is not being used? > So what is it for? > > Best regards, > Michael > > > Confirmed. I don't see imlim anywhere except in the imsh

Re: [Matplotlib-users] error reading netcdf file

2012-09-27 Thread Benjamin Root
Michael, The .missing_value attribute is not used anymore (It is ._FillValue now). Anyway, if your data had any value that matched ._FillValue, then, by default, netCDF4 will give you a masked array anyway. You will only need to set the mask if the fill value doesn't exist or if it is different f

Re: [Matplotlib-users] bug with bar graph when plotting zero values?

2012-09-27 Thread Benjamin Root
On Thursday, September 27, 2012, Pierre Haessig wrote: > Hi Paul, > > Le 26/09/2012 18:14, Paul Tremblay a écrit : > > I noticed today that when I create a bar graph with zero values that > > the labels don't align correctly: > > When I run your code with defects = [0, 0, 0, 5, 6, 7], I don't noti

Re: [Matplotlib-users] error reading netcdf file

2012-09-26 Thread Benjamin Root
On Wed, Sep 26, 2012 at 2:07 PM, Michael Rawlins wrote: > > > -- > *From:* Benjamin Root > *To:* Michael Rawlins > *Cc:* "matplotlib-users@lists.sourceforge.net" < > matplotlib-users@lists.sourceforge.net> > *Sent:* Wednesday

Re: [Matplotlib-users] example of pareto chart

2012-09-26 Thread Benjamin Root
On Wed, Sep 26, 2012 at 12:10 PM, Paul Tremblay wrote: > Thanks. I know when doing 8/9 in python 2.x you get 0. With python 3 you > get a decimal (Hooray, Python 3!). > > I ran the script I submitted with python 3. Do I need to change the > defects and totals from integers to floats to make my cha

Re: [Matplotlib-users] synchronization of ticks position in twinx plots

2012-09-26 Thread Benjamin Root
On Wed, Sep 26, 2012 at 11:07 AM, Pierre Haessig wrote: > Le 26/09/2012 15:30, Benjamin Root a écrit : > > > > Probably could have the two axes listen for an "xlim_changed" event, > > check to see if it belongs to its twin, and update itself accordingly > > (

Re: [Matplotlib-users] error reading netcdf file

2012-09-26 Thread Benjamin Root
On Wed, Sep 26, 2012 at 10:27 AM, Michael Rawlins wrote: > Recently built and installed netCDF4-1.0. I'm running a script that has > worked on two other linux OS systems. Error: > > File "test.py", line 96, in > data.missing_value=-9.99 > File "netCDF4.pyx", line 2570, in netCDF4.Variable.

Re: [Matplotlib-users] default data sets for matplotlib?

2012-09-26 Thread Benjamin Root
On Wed, Sep 26, 2012 at 9:10 AM, Michael Droettboom wrote: > On 09/26/2012 12:28 AM, josef.p...@gmail.com wrote: > > On Wed, Sep 26, 2012 at 12:05 AM, Paul Tremblay > wrote: > >> In R, there are many default data sets one can use to both illustrate > code > >> and explore the scripting language.

Re: [Matplotlib-users] synchronization of ticks position in twinx plots

2012-09-26 Thread Benjamin Root
On Wed, Sep 26, 2012 at 5:58 AM, Pierre Haessig wrote: > Hello, > > In relation to the recent thread on pareto chart, I have a question with > regards to the synchronization of ticks location when using twinx plots. > This question may have been adressed in the past, but my Google search > on this

Re: [Matplotlib-users] example of pareto chart

2012-09-26 Thread Benjamin Root
On Wed, Sep 26, 2012 at 4:31 AM, Pierre Haessig wrote: > Hi, > > Just a detail : > > Le 26/09/2012 04:29, Paul Tremblay a écrit : > > percent = (np.divide(the_cumsum, the_sum)) * 100 > > This lines doesn't work on my computer (numpy 1.6.2) > > Indeed, there is a casting issue : > In [2]: percent

Re: [Matplotlib-users] resolution on plotting for "retina" displays?

2012-09-25 Thread Benjamin Root
On Tue, Sep 25, 2012 at 8:53 AM, mdekauwe wrote: > I tried your suggestions...the first one (Qt4Agg) resulted in an error > (below) so it looks like I am missing some packages and the second option > (TkAgg) pretty much gave the same quality as the macosx backend. > > thanks. > > I am still doubt

Re: [Matplotlib-users] resolution on plotting for "retina" displays?

2012-09-25 Thread Benjamin Root
On Tue, Sep 25, 2012 at 8:14 AM, mdekauwe wrote: > Hi, > > For all those using newer macs [and I assume other newer computers] the > resolution on the plt.show popup window is a little rough (not sure of the > technical name). Is there a way to double up the resolution? I tried > changing a few t

Re: [Matplotlib-users] A pie chart with rotated text labels

2012-09-24 Thread Benjamin Root
On Monday, September 24, 2012, Martin Mokrejs wrote: > Hi, > I have pie charts with relatively long texts assigned to each slice of > the pie. > The text is drawn horizontally. Instead, I would like to have it rotated > at the > same angle as the slice itself (i.e. centered at the "axis" of the

Re: [Matplotlib-users] example of pareto chart

2012-09-24 Thread Benjamin Root
On Mon, Sep 24, 2012 at 12:21 AM, Paul Tremblay wrote: > Here is my example of a Pareto chart. > > For an explanation of a Pareto chart: > > http://en.wikipedia.org/wiki/Pareto_chart > > Could I get this chart added to the matplolib gallery? > > > Thanks > > Paul > > Your code looks overly complic

Re: [Matplotlib-users] Correct versions of old commands

2012-09-23 Thread Benjamin Root
On Sunday, September 23, 2012, Giovanni Plantageneto wrote: > Hi everybody, > sorry, I guess the question is trivial, but I confess my matplotlib > and python ignorance. > > I'm running some code written by someone else, and apparently some > bits of the code are not compliant with newer versions

[Matplotlib-users] Fwd: install problem on OSX 10.8

2012-09-21 Thread Benjamin Root
From: Ranjit Chacko Date: Fri, Sep 21, 2012 at 2:55 PM Subject: Re: [Matplotlib-users] install problem on OSX 10.8 To: Benjamin Root I'm just cloned the repo from master yesterday, and I tried running the following script: NAME=matplotlib VERSION=v1.1.x PREFIX=$HOME cd matplotlib export L

Re: [Matplotlib-users] install problem on OSX 10.8

2012-09-21 Thread Benjamin Root
On Fri, Sep 21, 2012 at 2:19 PM, Ranjit Chacko wrote: > I'm having some trouble compiling matplotlib, and I'm not sure how to fix > it. Does anyone have any advice on how to proceed given the following > traceback? > > Thanks, > > -Ranjit > > Which version of matplotlib? How are you building it

Re: [Matplotlib-users] Is it possible to have different color for inner and outer face of a 3D plot?

2012-09-21 Thread Benjamin Root
On Wed, Sep 19, 2012 at 9:14 AM, Fabien Lafont wrote: > Actually I want to try to plot something like this picture: > > http://physics.aps.org/assets/d88621a594e78eea > > With a color for inside and another for outside. > > Probably not to the level of control one may wish to have, but one can ach

Re: [Matplotlib-users] mplot3d grid/axes

2012-09-20 Thread Benjamin Root
On Thursday, September 20, 2012, Brian J Mingus wrote: > Hi all, > > I have managed to create a 3d plot with uneven aspect ratio via > auto_scale_xyz but I haven't yet figured out how to fix the grid. If you > could give me a pointer I would appreciate it. > > http://imagebin.org/index.php?mode=im

Re: [Matplotlib-users] Missing bar when last value is 0

2012-09-19 Thread Benjamin Root
On Wednesday, September 19, 2012, Adam Davis wrote: > If I do: > > bar(range(3), [1,0,2]) > > ... then I get 2 bars of a suitable width for a 3 bar chart, with a gap in > between where the middle bar would be if not equal to 0. Yet if I do: > > bar(range(3), [1,2,0]) > > ... then I get two

Re: [Matplotlib-users] animation or movie

2012-09-18 Thread Benjamin Root
On Tue, Sep 18, 2012 at 3:10 PM, gsal wrote: > Animation/movie advice. > > So, earlier, I got some help in finding out about pcolorfast that allowed > me > to plot some data as a nice contour. > > Now, I would like to get fancier and actually take a look as such contour > as > it varies with time

Re: [Matplotlib-users] overwriting suptitle?

2012-09-16 Thread Benjamin Root
On Sun, Sep 16, 2012 at 2:09 PM, Skipper Seabold wrote: > Is there a way to overwrite suptitle? When using 3rd party libs that > return a figure, if they set suptitle and don't give you the text > object back then you can't overwrite it? This doesn't seem right to > me. > > > http://stackoverflow.

Re: [Matplotlib-users] Need to plot z at given x, y...contour? or something!

2012-09-14 Thread Benjamin Root
On Fri, Sep 14, 2012 at 3:50 PM, Eric Firing wrote: > On 2012/09/14 9:00 AM, Benjamin Root wrote: > > tricontourf() might be more what you are looking for. Another > > possibility is pcolor() (note that for irregularly spaced grids, > > pcolormesh() would not work). > &g

Re: [Matplotlib-users] Need to plot z at given x, y...contour? or something!

2012-09-14 Thread Benjamin Root
On Fri, Sep 14, 2012 at 2:51 PM, gsal wrote: > Hi, everybody: > > I don't have experience with images or contours and need some help plotting > a 'z' quantity for given x,y coordinates. > > What are the choices? > > Here is a small sample of the data: > > The first row has the i-th x-coordinate

Re: [Matplotlib-users] legend(loc='best') not so great

2012-09-11 Thread Benjamin Root
On Tue, Sep 11, 2012 at 9:29 AM, Neal Becker wrote: > I tried a scatterplot with legend(loc='best'), but the legend > appears on the upper right, covering a data point. There is nothing > anywhere > in the graph on the upper left, which is where 'best' should go. > > A small, self-contained exam

Re: [Matplotlib-users] numpoints in legend() function for scatter plot is not working in matplotlib 1.1.0?

2012-09-10 Thread Benjamin Root
directions? We have several for different kinds of installs. We have not released v1.2.0 yet, so I was guessing you checked out mpl from github. If that is the case, then you run "git log" from the source directory, not the install directory. Ben > > On Mon, Sep 10, 2012 at 3:05 PM

Re: [Matplotlib-users] numpoints in legend() function for scatter plot is not working in matplotlib 1.1.0?

2012-09-10 Thread Benjamin Root
On Mon, Sep 10, 2012 at 2:56 AM, Chao YUE wrote: > Hi Ben, > > I tried the "numpoints" in legend function for scatter plot, in dev > version and GTKAgg backend it works. > > In [3]: mat.__version__ > Out[3]: '1.2.x' > > In [4]: mat.get_backend() > Out[4]: 'GTKAgg' > > Chao > > Strange, when I tes

Re: [Matplotlib-users] markeredgecolor (mec) in the plot function not working?

2012-09-09 Thread Benjamin Root
On Tue, Apr 10, 2012 at 12:22 PM, wiswit wrote: > Dear all, I use matplotlib 1.1.0. import matplotlib.pyplot as plt > plt.plot(np.arange(10),'ro',mec='none') when I use plt.show(), there is > only blank frame with axis not no points. but plt.plot(np.arange(10),'ro') > will give good plot with rea

Re: [Matplotlib-users] numpoints in legend() function for scatter plot is not working in matplotlib 1.1.0?

2012-09-09 Thread Benjamin Root
On Tue, Apr 10, 2012 at 12:43 PM, wiswit wrote: > > Dear all, > > I found that the numpoints in legend function for scatter plot is not > working? > > import matplotlib as mat > import matplotlib.pyplot as plt > In [59]: mat.__version__ > Out[59]: '1.1.0' > > #ordinary plot working > fig=plt.figu

Re: [Matplotlib-users] plt.close() not releasing memory? Or memory leak elsewhere?

2012-09-09 Thread Benjamin Root
On Tue, May 22, 2012 at 9:18 AM, Stevenson, Samuel < samuel.steven...@coherent.com> wrote: > Hi Ben > > ** ** > > I am using 1.0.0. My colleague has 1.1.0 installed on his machine and is > able to reproduce the same problem. > > ** ** > > Thanks > > > Sam > Going through my old unreso

Re: [Matplotlib-users] Saving figure instance for reuse

2012-09-09 Thread Benjamin Root
On Wed, Aug 15, 2012 at 5:40 AM, Jesper Larsen wrote: > Hi Matplotlib users > > I have an application where performance is critical and matplotlib is > the performance bottleneck. I am making a lot of figures using the > same basic setup of the figure. And from my profiling I can see that > this b

Re: [Matplotlib-users] Using the lasso tool when file is not main

2012-09-07 Thread Benjamin Root
I think I see your problem... see below: class start_lasso(): def __init__(self): data = [Datum(*xy) for xy in rand(100, 2)] fig = figure() ax = fig.add_subplot(111, xlim=(0,1), ylim=(0,1), autoscale_on=False) lman = LassoManager(ax, data) show() You

Re: [Matplotlib-users] MemoryError with NetCDF

2012-09-07 Thread Benjamin Root
On Fri, Sep 7, 2012 at 9:49 AM, Shahar Shani-Kadmiel wrote: > On Sep 7, 2012, at 4:25 PM, Benjamin Root wrote: > > > > On Fri, Sep 7, 2012 at 8:44 AM, Shahar Shani-Kadmiel < > kadm...@post.bgu.ac.il> wrote: > >> 1. an ipython session is invoked with qtconsole --

Re: [Matplotlib-users] MemoryError with NetCDF

2012-09-07 Thread Benjamin Root
On Fri, Sep 7, 2012 at 8:44 AM, Shahar Shani-Kadmiel wrote: > 1. an ipython session is invoked with qtconsole --pylab > 2. I load a large NetCDF grid (Grid file format: nf (# 18) GMT netCDF > format (float) (COARDS-compliant) [DEFAULT]), approx. 1.15 GB > 3. I then try to plot with imshow the da

Re: [Matplotlib-users] Rectangle Bug

2012-09-06 Thread Benjamin Root
On Thursday, September 6, 2012, jonasr wrote: > Hello, > > i spotted a bug in the Rectangle function when plotting with multiple > subplot, here is a source code example: > > #!/usr/bin/env python > # -*- coding: utf-8 -*- > > from matplotlib.pyplot import * > from numpy import * > import sys, os

Re: [Matplotlib-users] Matplotlib navigation toolbar, save image & image text

2012-09-06 Thread Benjamin Root
On Thu, Sep 6, 2012 at 4:37 PM, Jon Roadley-Battin < jon.roadleybat...@gmail.com> wrote: > On 6 September 2012 14:55, Jon Roadley-Battin > wrote: > > On 6 September 2012 14:20, Benjamin Root wrote: > >> > >> > >> On Thu, Sep 6, 2012 at 5:29 AM, Jon

Re: [Matplotlib-users] subscript size different than in LaTeX document

2012-09-06 Thread Benjamin Root
On Thu, Sep 6, 2012 at 6:54 AM, Mogliii wrote: > Hi, > > I am preparing figures with the following matplotlib preamble: > > plt.rc('font', **{'family':'serif', 'serif':['Computer Modern Roman'], > 'monospace':['Computer Modern Typewriter']}) > params = {'backend': 'ps', >

Re: [Matplotlib-users] Matplotlib navigation toolbar, save image & image text

2012-09-06 Thread Benjamin Root
On Thu, Sep 6, 2012 at 5:29 AM, Jon Roadley-Battin < jon.roadleybat...@gmail.com> wrote: > Good morning, > > I have an odd problem with saving plot images via the navigation bar > (unsure if it is unique to the navigation bar) if I have added custom > text. > > BACKGROUND. > I have a python gui wh

Re: [Matplotlib-users] type error with python 3.2 and version 1.1.1 of matplotlib (numpy error)

2012-09-06 Thread Benjamin Root
On Thu, Sep 6, 2012 at 2:24 AM, Eric Firing wrote: > On 2012/09/05 6:17 PM, Paul Tremblay wrote: > > Hmm. I found that mpl handled my datetime objects just fine: > > Right, mpl has handled python datetime objects for a long time, but the > numpy array with a datetime dtype is a new and different

Re: [Matplotlib-users] Using the lasso tool when file is not main

2012-09-05 Thread Benjamin Root
On Wednesday, September 5, 2012, Mark Budde wrote: > Hi, > I'm not an expert so please go easy on me. I am using the pyplot lasso > demo, and have got it to work how I would like. I am having a problem, > however, where I cannot get it to work if my python file is not the > main file (where __name

Re: [Matplotlib-users] Limit data for plot Basemap

2012-09-04 Thread Benjamin Root
On Fri, Aug 24, 2012 at 12:21 PM, John Bluee wrote: > I have lat and lon as coordinates and to each point a value. So far I use > contourf to plot. > > Sorry for not getting back to you sooner. May I suggest the following: values = np.ma.masked_outside(values, -1e-8, 1e-9, copy=False) values =

Re: [Matplotlib-users] type error with python 3.2 and version 1.1.1 of matplotlib (numpy error)

2012-09-04 Thread Benjamin Root
On Tue, Sep 4, 2012 at 3:24 PM, Eric Firing wrote: > On 2012/09/04 9:09 AM, Benjamin Root wrote: > > > > > > On Tue, Sep 4, 2012 at 2:20 PM, Paul Tremblay > <mailto:paulhtremb...@gmail.com>> wrote: > > > > > > The following Python code:

Re: [Matplotlib-users] type error with python 3.2 and version 1.1.1 of matplotlib (numpy error)

2012-09-04 Thread Benjamin Root
On Tue, Sep 4, 2012 at 2:20 PM, Paul Tremblay wrote: > > The following Python code: > > >>ax.fill_between(dates, lower, upper, facecolor='gray', alpha=0.5) > > Produces this error with Python 3.2: > > Traceback (most recent call last): > File "scripts/audit_reports_weekly.py", line 150, in >

Re: [Matplotlib-users] animation framework problem

2012-09-04 Thread Benjamin Root
On Mon, Sep 3, 2012 at 4:26 PM, Gyro Funch wrote: > Hi, > > I am trying to create a multi-subplot animation with based loosely > on the animation example code, subplots.py, at > http://matplotlib.sourceforge.net/examples/animation/subplots.html > > A simplified version of the full code is shown a

Re: [Matplotlib-users] how to avoid import backend in the batch job?

2012-09-03 Thread Benjamin Root
On Monday, September 3, 2012, Chao YUE wrote: > Dear all, > > I have a module written by myself which use > python-netcdf/matplotlib/numpy/basemap for treating and mapping of netcdf > files. > so in the module I have a line: > > import matplotlib.pyplot as plt > > But now I am using some function

Re: [Matplotlib-users] Legend Marker Color Bug

2012-08-30 Thread Benjamin Root
On Thu, Aug 30, 2012 at 3:26 PM, Goyo wrote: > 2012/8/28 Sterling Smith : > > List, > > > > Consider the following script: > > > > import pylab > > pylab.plot(pylab.linspace(0,1,100),label='Test',marker='o',ls='') > > pylab.plot(pylab.linspace(0,1,100),label='Test2',marker='o',ls='-') > > leg=pyl

Re: [Matplotlib-users] How to insert an image in a plot?

2012-08-30 Thread Benjamin Root
There is imshow(), which will plot an array into the existing axes, as well as figimage(), which will insert the image into the figure in general. Each of these function have ways to control placement, particularly figimage(). Without more information, I can't help much further. Cheers! Ben Root

Re: [Matplotlib-users] How to change the size of the numbers under the axis

2012-08-30 Thread Benjamin Root
On Thu, Aug 30, 2012 at 1:38 PM, Fabien Lafont wrote: > I'm just trying to plot a graph and add a label to each axis of that graph > and change the labelsize of the ticks. > > Could you post your code? What you are describing shouldn't happen. Also, which version of matplotlib are you using? Be

Re: [Matplotlib-users] How to change the size of the numbers under the axis

2012-08-30 Thread Benjamin Root
On Thu, Aug 30, 2012 at 12:53 PM, Fabien Lafont wrote: > Hi, > > But how can I do it for every graph and without creating axis? > > > We just told you: import matplotlib matplotlib.rcParams['xticks.labelsize'] = 12.0 Whenever a plot is made, it obtains the defaults from the rcParams. Note, if y

Re: [Matplotlib-users] How to change the size of the numbers under the axis

2012-08-30 Thread Benjamin Root
On Thu, Aug 30, 2012 at 11:58 AM, Fabien Lafont wrote: > There is no effect... > > > 2012/8/30 Damon McDougall > >> On Thu, Aug 30, 2012 at 05:50:18PM +0200, Fabien Lafont wrote: >> > Hello, >> > >> > Do you know to change the size of the numbers under the axis? >> > >> >> import matplotlib >> ma

Re: [Matplotlib-users] Store figures as matlab files

2012-08-29 Thread Benjamin Root
On Wed, Aug 29, 2012 at 2:11 PM, Nils Wagner wrote: > Hi all, > > is it possible to store figures generated with matplotlib as Matlab files ? > > Cheers, > Nils > > This is an often repeated question, and the last time I remember it being asked, someone pointed out that the matla

Re: [Matplotlib-users] Background basemaps in Basemap

2012-08-25 Thread Benjamin Root
On Saturday, August 25, 2012, Jeff Whitaker wrote: > On 8/24/12 10:20 PM, klo uo wrote: > > On Sat, Aug 25, 2012 at 1:26 AM, Jeff Whitaker wrote: > >> Oh sure, it's simple! > >> > >> http://www.google.com/patents?id=J4YOEBAJ&dq=6618053 > > Hi Jeff, > > > > thanks for your reply. > > > > I was

Re: [Matplotlib-users] Limit data for plot Basemap

2012-08-24 Thread Benjamin Root
On Fri, Aug 24, 2012 at 11:57 AM, John Bluee wrote: > Hi all > > I have to plot seismic data on a worldmap and use the Basemap framework to > do it. > My dataset contains important data in the range of -1e-8 to -1e-14 and > 1e-14 to 1e-9. Can I limit the plot to only display data in this range? >

Re: [Matplotlib-users] GCC error when building matplotlib

2012-08-24 Thread Benjamin Root
On Fri, Aug 24, 2012 at 6:35 AM, Joe Borġ wrote: > Hi, > > I've reinstalled numpy and the error from gcc has changed. Please see > log, all the system information should be in there. > > Matplotlib 1.1.1 does not work with py3k. We are just about ready to release v1.2.0 which will work with py3

Re: [Matplotlib-users] GCC failure when updating from 1.1.0 to 1.1.1

2012-08-22 Thread Benjamin Root
On Wed, Aug 22, 2012 at 12:31 PM, Joe Borġ wrote: > Not sure if this is an issue with an out-of-date GCC or if something else > is wrong. I've got 1.1.0 on no problem. > > $python setup.py build > ... > gcc -pthread -fno-strict-aliasing -g -O2 -DNDEBUG -g -fwrapv -O3 -Wall > -fPIC -DPY_ARRAY_UNI

Re: [Matplotlib-users] Any available backend for non-root users?

2012-08-16 Thread Benjamin Root
On Thu, Aug 16, 2012 at 4:26 PM, Liang Wang wrote: > Hi everyone. I have trouble to find a usable background on a remote server > where I do not have root privilege. Unfortunately, there is no backend > available: > >Tkinter: no > * Using default library an

Re: [Matplotlib-users] NavigationToolbar2WxAgg Buttons Disappear

2012-08-15 Thread Benjamin Root
On Wednesday, August 15, 2012, David Grudoski wrote: > Hi All, > I've encountered this problem with the both NavigationToolbar2Wx and the > NavigationToolbar2WxAgg. > When I click the Zoom or Pan button the button disappears. The > functionality is maintained so if a click the location that the bu

Re: [Matplotlib-users] Saving figure with an image and a time axis as an EPS shifts image relative to other plot features

2012-08-13 Thread Benjamin Root
On Thu, Aug 2, 2012 at 7:21 PM, Chad Parker wrote: > Hello everyone- > > I'm a new Python/Matplotlib user, but I have quite a bit of plotting > experience with octave/matlab and gnuplot. So, I apologize in advance if my > python style is terrible and if I give you all the wrong information! > > I'

Re: [Matplotlib-users] New tutorial (beginner level)

2012-08-11 Thread Benjamin Root
On Saturday, August 11, 2012, Fernando Perez wrote: > On Sat, Aug 11, 2012 at 12:09 AM, Nicolas Rougier > > wrote: > > By the way, I suspect the simple plot part may well suited for the > ipython notebook ! > > I'll give it a try. > > Actually in the notebook it is now possible to enable exercises

Re: [Matplotlib-users] New tutorial (beginner level)

2012-08-10 Thread Benjamin Root
On Fri, Aug 10, 2012 at 8:23 AM, Nicolas Rougier wrote: > > > Hi all, > > > I've just finished a new introductory tutorial for incoming Euroscipy > 2012. You can find it here: > > http://www.loria.fr/~rougier/teaching/matplotlib/ > > > It is based on Mike Müller tutorial from scipy lecture notes (

Re: [Matplotlib-users] Fwd: zoomed in detail box

2012-08-09 Thread Benjamin Root
On Wed, Aug 8, 2012 at 7:03 AM, darkside wrote: > > > -- Forwarded message -- > From: darkside > Date: 2012/8/2 > Subject: Re: [Matplotlib-users] zoomed in detail box > To: Jae-Joon Lee > > > Hi everyone! > > I'm also trying to do a detailed zoomed area of my plot, but I can't >

Re: [Matplotlib-users] Using object oriented interface in interactive mode?

2012-08-05 Thread Benjamin Root
On Sunday, August 5, 2012, Nikolaus Rath wrote: > Benjamin Root > > writes: > > On Sunday, August 5, 2012, Nikolaus Rath wrote: > > > >> Hello, > >> > >> The following code shows the plot right away as expected: > >> > >> # pyth

Re: [Matplotlib-users] Using object oriented interface in interactive mode?

2012-08-05 Thread Benjamin Root
On Sunday, August 5, 2012, Nikolaus Rath wrote: > Hello, > > The following code shows the plot right away as expected: > > # python > Python 2.7.3rc2 (default, Apr 22 2012, 22:30:17) > [GCC 4.6.3] on linux2 > Type "help", "copyright", "credits" or "license" for more information. > >>> import matpl

Re: [Matplotlib-users] Size of array elements when using Axes3D.plot_wireframe(X, Y, Z, *args, **kwargs)

2012-08-02 Thread Benjamin Root
On Friday, August 3, 2012, surfcast23 wrote: > > I tested it out and it does change all the values to ones and zeros. Is > there > a way to broadcast and keep the original values that were in the arrays? > Thanks for the help > > > Don't use ones() and zeros(). It was just a way to swtup a demons

Re: [Matplotlib-users] Size of array elements when using Axes3D.plot_wireframe(X, Y, Z, *args, **kwargs)

2012-08-02 Thread Benjamin Root
On Thursday, August 2, 2012, surfcast23 wrote: > > Wouldn't > > X= np.ones((1, 45)) > Y= np.zeros((32, 1)) > > change the existing values of the elements to ones and zeros? > > I was just demonstrating what np.broadcast_arrays() does. Take your x and y arrays and put them through this function an

Re: [Matplotlib-users] Size of array elements when using Axes3D.plot_wireframe(X, Y, Z, *args, **kwargs)

2012-08-02 Thread Benjamin Root
On Thursday, August 2, 2012, surfcast23 wrote: > > Okay thank you! The Matlab code I am basing this on takes arrays of > different > shapes with different sized elements ie > x = 1 512 > y = 101 1 > and I guess automatically makes the the same shape. Can you point me in the > direction of docu

Re: [Matplotlib-users] Size of array elements when using Axes3D.plot_wireframe(X, Y, Z, *args, **kwargs)

2012-08-02 Thread Benjamin Root
On Thursday, August 2, 2012, surfcast23 wrote: > > > > surfcast23 wrote: > > > > In the documentation it says that Axes3D.plot_wireframe(X, Y, Z, *args, > > **kwargs) takes 2D arrays as the first two arguments. Do the arrays have > > to have the same size dimensions? > > > > > > Any one know? Wo

Re: [Matplotlib-users] reusing the pylab gui in a custom application (wxpython)?

2012-07-31 Thread Benjamin Root
On Sun, Jul 29, 2012 at 7:39 PM, Vlastimil Brom wrote: > 2012/7/30 Benjamin Root : > > > > > > On Sunday, July 29, 2012, Vlastimil Brom wrote: > >> > >> Hi all, > >> I'd like to ask about the possibility to eventually reuse the gui of >

Re: [Matplotlib-users] reusing the pylab gui in a custom application (wxpython)?

2012-07-29 Thread Benjamin Root
On Sunday, July 29, 2012, Vlastimil Brom wrote: > Hi all, > I'd like to ask about the possibility to eventually reuse the gui of > pylab for showing and manipulating the plots in the custom application > (written in wxpython). > Basically, I'd like to add some application specific controls to the

Re: [Matplotlib-users] Role of numpy Method arange in Matplotlib

2012-07-27 Thread Benjamin Root
On Friday, July 27, 2012, JonBL wrote: > > I'm unsure about the role of numpy method arange in Matplotlib plots. All > Matplotlib examples I have seen call numpy's method arange, and pass the > result as the first arg to Matplotlib's plot method. > > But the following works as expected: > > --- qu

<    1   2   3   4   5   6   7   8   9   10   >