Re: [Matplotlib-users] example of pareto chart

2012-09-26 Thread Pierre Haessig
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 Out[2]: array([ 0, 0, 0, 0, 100]) However, using the regular /

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

2012-09-26 Thread Michael Droettboom
On 09/26/2012 12:28 AM, josef.p...@gmail.com wrote: On Wed, Sep 26, 2012 at 12:05 AM, Paul Tremblay paulhtremb...@gmail.com wrote: In R, there are many default data sets one can use to both illustrate code and explore the scripting language. Instead of having to fake data, one can pull from

Re: [Matplotlib-users] example of pareto chart

2012-09-26 Thread Benjamin Root
On Wed, Sep 26, 2012 at 4:31 AM, Pierre Haessig pierre.haes...@crans.orgwrote: 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

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 pierre.haes...@crans.orgwrote: 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

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 md...@stsci.edu wrote: On 09/26/2012 12:28 AM, josef.p...@gmail.com wrote: On Wed, Sep 26, 2012 at 12:05 AM, Paul Tremblay paulhtremb...@gmail.com wrote: In R, there are many default data sets one can use to both illustrate code and

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

2012-09-26 Thread josef . pktd
On Wed, Sep 26, 2012 at 9:33 AM, Benjamin Root ben.r...@ou.edu wrote: On Wed, Sep 26, 2012 at 9:10 AM, Michael Droettboom md...@stsci.edu wrote: On 09/26/2012 12:28 AM, josef.p...@gmail.com wrote: On Wed, Sep 26, 2012 at 12:05 AM, Paul Tremblay paulhtremb...@gmail.com wrote: In R, there

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

2012-09-26 Thread Michael Droettboom
On 09/26/2012 09:33 AM, Benjamin Root wrote: On Wed, Sep 26, 2012 at 9:10 AM, Michael Droettboom md...@stsci.edu mailto:md...@stsci.edu wrote: On 09/26/2012 12:28 AM, josef.p...@gmail.com mailto:josef.p...@gmail.com wrote: On Wed, Sep 26, 2012 at 12:05 AM, Paul Tremblay

[Matplotlib-users] error reading netcdf file

2012-09-26 Thread Michael Rawlins
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 module     data.missing_value=-9.99   File netCDF4.pyx, line 2570, in netCDF4.Variable.__setattr__ (netCDF4.c:28242)   File netCDF4.pyx, line 2392, in

Re: [Matplotlib-users] error reading netcdf file

2012-09-26 Thread Benjamin Root
On Wed, Sep 26, 2012 at 10:27 AM, Michael Rawlins rawlin...@yahoo.comwrote: 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 module data.missing_value=-9.99 File netCDF4.pyx, line 2570, in

Re: [Matplotlib-users] example of pareto chart

2012-09-26 Thread Pierre Haessig
Le 26/09/2012 15:25, Benjamin Root a écrit : Actually, if you are using the latest numpy (the 1.7 beta), that will also not work unless you are using py3k or did from __future__ import division. Well, actually, using np.divide will always result in integer division (this may or may not be a

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

2012-09-26 Thread Pierre Haessig
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 (without emitting). I guess you mean ylim_changed event ? (Maybe my description was not very clear, but the

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 pierre.haes...@crans.orgwrote: 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 (without emitting). I

Re: [Matplotlib-users] example of pareto chart

2012-09-26 Thread Paul Tremblay
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 chart work universally? P. On Wed, Sep 26, 2012 at 4:31 AM,

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

2012-09-26 Thread Paul Tremblay
I noticed today that when I create a bar graph with zero values that the labels don't align correctly: import matplotlib.pyplot as plt import numpy as np fig = plt.figure() names = ['name a', 'name b', 'name c', 'named', 'name e', 'name f'] defects = [0, 0, 0, 5, 6, 7] ax = fig.add_subplot(111)

Re: [Matplotlib-users] trouble with show() not drawing in interactive mode w/ WxAgg

2012-09-26 Thread Craig the Demolishor
So I rebuilt Python so that I would have Tkinter support, and using TkAgg I get the behavior I want, so it's not mission critical to me to figure this out anymore. But if anyone is interested in tracking it down I will be glad to help. On Wed, Sep 26, 2012 at 8:06 AM, Craig the Demolishor

Re: [Matplotlib-users] example of pareto chart

2012-09-26 Thread Benjamin Root
On Wed, Sep 26, 2012 at 12:10 PM, Paul Tremblay paulhtremb...@gmail.comwrote: 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

Re: [Matplotlib-users] error reading netcdf file

2012-09-26 Thread Michael Rawlins
From: Benjamin Root ben.r...@ou.edu To: Michael Rawlins rawlin...@yahoo.com Cc: matplotlib-users@lists.sourceforge.net matplotlib-users@lists.sourceforge.net Sent: Wednesday, September 26, 2012 10:33 AM Subject: Re: [Matplotlib-users] error reading netcdf

Re: [Matplotlib-users] error reading netcdf file

2012-09-26 Thread Benjamin Root
On Wed, Sep 26, 2012 at 2:07 PM, Michael Rawlins rawlin...@yahoo.comwrote: -- *From:* Benjamin Root ben.r...@ou.edu *To:* Michael Rawlins rawlin...@yahoo.com *Cc:* matplotlib-users@lists.sourceforge.net matplotlib-users@lists.sourceforge.net *Sent:*

Re: [Matplotlib-users] error reading netcdf file

2012-09-26 Thread Jeff Whitaker
On 9/26/12 1:41 PM, Benjamin Root wrote: On Wed, Sep 26, 2012 at 2:07 PM, Michael Rawlins rawlin...@yahoo.com mailto:rawlin...@yahoo.com wrote: *From:* Benjamin Root ben.r...@ou.edu

Re: [Matplotlib-users] error reading netcdf file

2012-09-26 Thread Michael Rawlins
From: Jeff Whitaker jeffrey.s.whita...@noaa.gov To: Benjamin Root ben.r...@ou.edu; Michael Rawlins rawl...@geo.umass.edu; Matplotlib Users matplotlib-users@lists.sourceforge.net Sent: Wednesday, September 26, 2012 5:10 PM Subject: Re: [Matplotlib-users] error