Re: [Matplotlib-users] Include \hline on table inside figure

2015-01-23 Thread C M
On Fri, Jan 23, 2015 at 1:42 PM, Thomas Caswell tcasw...@gmail.com wrote: Have you looked at using the mpl tables? http://matplotlib.org/examples/pylab_examples/table_demo.html Just pointing out: the numbers in those tables and the words other than Quake are slightly cut-off at the top in

Re: [Matplotlib-users] odd singular matrix error

2015-01-02 Thread C M
Still though, I thought we had enough logic checks to prevent this sort of error. I see you are using Python 2.5, which is older than what we currently support. Which version of matplotlib are you using? I'm using matplotlib 1.1.0. I could try upgrading. Ben and others, OK, I tried

Re: [Matplotlib-users] odd singular matrix error

2014-12-31 Thread C M
1.1.0. I could try upgrading. Cheers! Ben Root On Wed, Dec 31, 2014 at 2:03 AM, C M cmpyt...@gmail.com wrote: I have no idea what this is. If I create a certain plot first in an application, it throws this error (edited to the key part): Traceback (most recent call last): File

[Matplotlib-users] odd singular matrix error

2014-12-30 Thread C M
I have no idea what this is. If I create a certain plot first in an application, it throws this error (edited to the key part): Traceback (most recent call last): File thescript.py, line 2147, in AddPatchBar ax.add_patch(patch) File C:\Python25\lib\site-packages\matplotlib\axes.py, line

Re: [Matplotlib-users] pick markers only but not the connecting line

2014-06-08 Thread C M
Great, thanks for all the help! On Sun, Jun 8, 2014 at 12:09 AM, Eric Firing efir...@hawaii.edu wrote: On 2014/06/07, 5:03 PM, C M wrote: On Sat, Jun 7, 2014 at 10:18 PM, Eric Firing efir...@hawaii.edu mailto:efir...@hawaii.edu wrote: On 2014/06/07, 4:12 PM, C M wrote

Re: [Matplotlib-users] event.ind in point picking gives wrong number

2014-06-07 Thread C M
one does. Any suggestions for what's wrong greatly appreciated. Thanks, Che On Mon, Sep 16, 2013 at 9:15 AM, Benjamin Root ben.r...@ou.edu wrote: On Sun, Sep 15, 2013 at 11:59 PM, C M cmpyt...@gmail.com wrote: Just a follow-up on this problem... I've found now that the index is only off

Re: [Matplotlib-users] event.ind in point picking gives wrong number

2014-06-07 Thread C M
On Sat, Jun 7, 2014 at 4:02 PM, Benjamin Root ben.r...@ou.edu wrote: Thanks for the example script. I think I have a clue now what is happening. Thank you for the quick reply. If one were to also print out the length of the d array, you will find that it is significantly shorter than when

[Matplotlib-users] pick markers only but not the connecting line

2014-06-07 Thread C M
I had been using a custom function (written originally by Jae-Joon and modified a little by me...quite a long time back now) that was working to allow point picking of markers, but *not* the line connecting them. However, I've now discovered with the help of this list that the function I am using

Re: [Matplotlib-users] colorbllind problem

2014-02-17 Thread C M
On Mon, Feb 17, 2014 at 1:15 PM, Gabriele Brambilla gb.gabrielebrambi...@gmail.com wrote: Hi, I'm dealing with a guy that is colorblind. Have you got any suggestion on how could I show a plot like the one attached to him? Is there an option in pyplot that write little numbers near the

[Matplotlib-users] event.ind in point picking gives wrong number

2013-09-15 Thread C M
I have Matplotlib 1.1.0, and am doing point picking (using the OO approach to Matplotlib, and embedded in wxPython). My relevant code is as follows: #connect the pick event to the pick event handler: self.cid = self.canvas.mpl_connect('pick_event', self.on_pick) #This is the relevant part of

Re: [Matplotlib-users] event.ind in point picking gives wrong number

2013-09-15 Thread C M
:30 PM, C M cmpyt...@gmail.com wrote: I have Matplotlib 1.1.0, and am doing point picking (using the OO approach to Matplotlib, and embedded in wxPython). My relevant code is as follows: #connect the pick event to the pick event handler: self.cid = self.canvas.mpl_connect('pick_event

Re: [Matplotlib-users] time axis format

2013-06-10 Thread C M
On Mon, Jun 10, 2013 at 8:08 PM, Sudheer Joseph sudheer.jos...@yahoo.comwrote: Thank you, So there is no way to get J F M A etc with out reducing font size? I bet there a number of ways. Offhand I don't know the one that, once I hear about it, I will say, D'oh, that's so easy but I bet it

Re: [Matplotlib-users] Trying to migrate to Python 3.2, Matplotlib 1.2.1

2013-04-19 Thread C M
On Thu, Apr 18, 2013 at 11:03 PM, John Ladasky john_lada...@sbcglobal.netwrote: . Reading more, I realize that the way I was getting GUI output previously (with Python 2.7 and Matplotlib 1.1) was through wxPython. Unfortunately, it appears that wxPython's star is fading, and a Python

Re: [Matplotlib-users] matplotlib is slow

2012-12-31 Thread C M
Resurrecting an old thread here On Tue, Mar 29, 2011 at 3:23 PM, David Kremer da...@david-kremer.fr wrote: I would recommend running the import in the Python profiler to determine where most of the time is going. When I investigated this a few years back, it was mainly due to loading

[Matplotlib-users] wrapping y axis tick labels?

2012-07-20 Thread C M
How possible would it be to wrap y axis tick labels after a certain text length? I have a horizontal bar plot where some bars' labels are too long and therefore cut off. I can scrunch the width of the whole plot to accommodate them, but I'd much rather wrap long text and allow a little more

Re: [Matplotlib-users] matplotlib for Mac OS 10.7 (Lion)

2012-04-24 Thread C M
Trying to help a Mac friend running OSX 10.7 (Lion) easily set up to test scripts I send him, and have some questions: 1) Can Matplotlib 1.1 run on the Python 2.7.2 version that comes with Lion? Yes. You can easily build it yoursef as long as you have XCode installed: - Edit

[Matplotlib-users] matplotlib for Mac OS 10.7 (Lion)

2012-04-20 Thread C M
Trying to help a Mac friend running OSX 10.7 (Lion) easily set up to test scripts I send him, and have some questions: 1) Can Matplotlib 1.1 run on the Python 2.7.2 version that comes with Lion? 2) When is there expected to be an installer for Matplotlib 1.1 for OSX 10.7? Thanks, Che

[Matplotlib-users] why does transform=None cause a patch not to be shown?

2012-03-21 Thread C M
For the following code, if I remove the transform=None a green patch is shown. If it is in, it is not shown. I would think that transform=None should have no effect. Why is this? Thanks, Che import matplotlib.pyplot as plt import matplotlib.patches as patches from matplotlib.path import Path

[Matplotlib-users] make a rectangle that doesn't change with zoom.

2012-03-20 Thread C M
I'm trying to make a rectangle that highlights a straight line of markers such that: 1) it surrounds/contains the points, basically like: -- | | | OO O

Re: [Matplotlib-users] custom markers from images?

2012-03-07 Thread C M
I've for now taken a different approach that means I won't need custom markers from images. But I'm just curious: is there any wish/plans in Matplotlib to add support for this? I think it could do a lot to expand what's possible in terms of the look and feel of plots (even without things

Re: [Matplotlib-users] custom markers from images?

2012-03-02 Thread C M
Right. It should be technically feasible to just simply tell figimage to use a different transformation object, but this might have implications elsewhere. I am very hazy in this part of mpl. Hmm, I've simplified the figimage to just this line: fig.figimage(im,100,100,origin=upper,

Re: [Matplotlib-users] custom markers from images?

2012-03-01 Thread C M
Yeah, there are better ways to do that, somewhat. The problem with the proposed solution is that it relies on non-public APIs, which are can be subject to change without deprecation. Instead, I would have created the figimage object with a particular transform object that would have placed

[Matplotlib-users] custom markers from images?

2012-02-29 Thread C M
I'd like to use, in one case, small loaded images (pngs) as markers on an interactive matplotlib plot (using the OO approach). I'd potentially like to be able to point-pick these markers, too, as well as have them update appropriately if the plot is resized. The only example I've been to find of

Re: [Matplotlib-users] 2 possible bugs with make_axes_area_auto_adjustable

2012-02-15 Thread C M
On Mon, Feb 13, 2012 at 12:48 PM, C M cmpyt...@gmail.com wrote: I noticed what is causing one of these issues: 1) When I point-pick on the plot, the plot area still jumps (expands vertically a small amount). It used to do this each time I point-picked, but after upgrading MPL it now just

Re: [Matplotlib-users] 2 possible bugs with make_axes_area_auto_adjustable

2012-02-13 Thread C M
I noticed what is causing one of these issues: 1) When I point-pick on the plot, the plot area still jumps (expands vertically a small amount). It used to do this each time I point-picked, but after upgrading MPL it now just does it the *first* time only. But is it possible it can be fixed

[Matplotlib-users] 2 possible bugs with make_axes_area_auto_adjustable

2012-02-09 Thread C M
Jae-Joon's code, make_axes_area_auto_adjustable has been a great help to dynamically resizing my plots' axes area--such an improvement. But there are two bugs I've noticed that I wonder if has been identified/fixed yet: 1) When I point-pick on the plot, the plot area still jumps (expands

Re: [Matplotlib-users] Change xaxis labels

2012-02-06 Thread C M
On Mon, Feb 6, 2012 at 9:23 AM, David Craig dcdavem...@gmail.com wrote: Hi, I have a plot and the xaxis shows number of seconds after a start point. I would like to convert them to days anyone know how to do this. I have looked at the documentation but cant find what I need. Couldn't you

Re: [Matplotlib-users] How matplotlib got me a job

2012-02-06 Thread C M
On Mon, Feb 6, 2012 at 2:59 PM, Benjamin Root ben.r...@ou.edu wrote: Alternate title: How I finally convinced my Dad that open-source can put food on the table. Since this entire story got started on this mailing list, I figured it would be appropriate to end it here. Inspiring and uplifting

[Matplotlib-users] Show custom tool on NavToolbar staying pressed in

2012-02-01 Thread C M
The standard navigation toolbar has tools that press in and stay pressed to put the interation into a mode, like zoom mode or pan mode. You press the zoom tool, it stays shown as pressed in while it's in that mode. I am trying to add a new custom tool to the toolbar, and want it to put things

Re: [Matplotlib-users] Show custom tool on NavToolbar staying pressed in

2012-02-01 Thread C M
On Wed, Feb 1, 2012 at 5:25 PM, C M cmpyt...@gmail.com wrote: The standard navigation toolbar has tools that press in and stay pressed to put the interation into a mode, like zoom mode or pan mode. You press the zoom tool, it stays shown as pressed in while it's in that mode. CORRECTION

Re: [Matplotlib-users] no leading 0 on times from DateFormatter

2012-01-30 Thread C M
On Mon, Jan 30, 2012 at 12:32 PM, Daryl Herzmann akrh...@iastate.eduwrote: On Sun, Jan 29, 2012 at 10:10 PM, C M cmpyt...@gmail.com wrote: If I use the DateFormatter, like this: mydateformatter = I'll get dates like (note the time part): Nov 27 2011 03:00 PM Instead, I'd

Re: [Matplotlib-users] Subplot x-tick labels overlap with each other and with titles

2012-01-29 Thread C M
On Wed, Jan 4, 2012 at 2:19 PM, Benjamin Root ben.r...@ou.edu wrote: On Wednesday, January 4, 2012, jeffsp jef...@gmail.com wrote: plt.tight_layout(), sweet it still makes the labels too close to read, even if they don't overlap. that is, they're just a continuous string of numbers

[Matplotlib-users] help with custom formatter rules

2011-11-28 Thread C M
As related to another question(s) I've posted, can someone help with this custom formatter? This is for use in a FunctionFormatter to be used on the y axis to format the ticks (in particular, to remove them when not wanted). Example: def CustomFormatter(self,y,i): if y 0:

Re: [Matplotlib-users] data free margin

2011-11-24 Thread C M
I don't know if this will work for you, but in your situation I would probably just make another axis for the data with no y value. Like, a short squat axis directly below the main axis. -Jeff Thanks. That crossed my mind, but I never tried it yet. I thought it would take up too much

Re: [Matplotlib-users] data free margin

2011-11-23 Thread C M
On Tue, Nov 22, 2011 at 3:09 PM, Nicolas Rougier nicolas.roug...@inria.frwrote: Is that what you want ? No ticks, no labels: import matplotlib.pyplot as plt plt.plot(np.arange(10), np.arange(10)) plt.ylim(0,10) plt.yticks(np.linspace(3,10,8)) plt.show() Thanks. That works in your

[Matplotlib-users] data free margin

2011-11-22 Thread C M
What's the best way in Matplotlib to have a y axis that doesn't have ticks/axis numbers near the bottom of the graph? I don't know if it would be specified as the bottom 1/10th of the graph or x amount of pixels or inches or whatever...just need a bit of extra y-less space there to plot values

Re: [Matplotlib-users] question about tight_layout()

2011-10-16 Thread C M
In your example code, do you see the error raised only when you include the tight_layout call? Yes. To see this (at least on my platform), you take the example code and try two things: 1) Comment IN this line: self.panel.Layout(). Run it and you'll get the error. 3) Now comment OUT the

Re: [Matplotlib-users] question about tight_layout()

2011-10-16 Thread C M
So, it seems that the issue is platform-dependent. OK. As for the error message, it seems that the subplot_params values (left, right, top, bottom, etc) calculated by the tight_layout routine is somehow corrupted. Why this happens is hard to track down unless I can reproduce the error. And

Re: [Matplotlib-users] question about tight_layout()

2011-10-15 Thread C M
On Sat, Oct 15, 2011 at 10:15 AM, Jae-Joon Lee lee.j.j...@gmail.com wrote: Figure.tight_layout() is a correct way. Do you see that error only when you use Figure.tight_plot (and not when you use plt.tight_layout)? Yes. What happen you try the script below. import matplotlib.pyplot as

[Matplotlib-users] question about tight_layout()

2011-10-14 Thread C M
Just trying out the latest mpl 1.1.0 and the tight_layout() method. I saw the guide written about it, but am a unsure how to use this when using the OO approach to using Matplotlib. When using pyplot, the method is: plt.tight_layout(). When using the OO form of mpl, is it:

Re: [Matplotlib-users] How do you Plot data generated by a python script?

2011-09-06 Thread C M
The problem is that I have a data set with ~1250 so I cant' do the sorting or finding the mean by hand. That's not a problem--that's programming! Even if you had a data set with five items you should be in the mind set that by hand is an 18th century approach. This will drive further progress

Re: [Matplotlib-users] How do you Plot data generated by a python script?

2011-09-03 Thread C M
On Sat, Sep 3, 2011 at 7:32 PM, mdekauwe mdeka...@gmail.com wrote: So you do want a histogram then? I assume you have all of this sorted then, the histogram function is very good. I don't think he's describing a histogram, because he is not plotting frequency of observations on the y axis, but

Re: [Matplotlib-users] How do you Plot data generated by a python script?

2011-08-25 Thread C M
On Thu, Aug 25, 2011 at 10:01 PM, surfcast23 surfcas...@gmail.com wrote: Hi,   there is only one column. so I want a plot of y and x. With y taking values running from 0 to n  or 7 in my example and x as the average of the values that are contained in the rows in my example it was 5.57. It

[Matplotlib-users] center figure.suptitle with axes.set_title

2011-08-05 Thread C M
For a figure with just one subplot, I want to have a larger main title (using figure.suptitle) and a smaller subtitle (using axes.set_title). However, using horizontalalignment = 'center' on both the suptitle and title doesn't center the two relative to each other, because my subplot varies in

[Matplotlib-users] simple question about locator every 0.5

2011-07-20 Thread C M
Sorry, this is super-simple, but I'm lost in the whole locator/formatter part of the docs. How can I make a locator that just places a tick at every multiple of 0.5 around the data? So the y axis would look like: 3.5 -- 3.0 -- 2.5 -- 2.0 -- 1.5 -- 1.0 -- etc. Thanks, Che

Re: [Matplotlib-users] simple question about locator every 0.5

2011-07-20 Thread C M
On Wed, Jul 20, 2011 at 7:24 PM, Buchholz, Greg gbuchh...@infiniacorp.com wrote: -Original Message- From: C M [mailto:cmpyt...@gmail.com] Sorry, this is super-simple, but I'm lost in the whole locator/formatter part of the docs. How can I make a locator that just places a tick at every

Re: [Matplotlib-users] simple question about locator every 0.5

2011-07-20 Thread C M
On Wed, Jul 20, 2011 at 7:56 PM, Gökhan Sever gokhanse...@gmail.com wrote: On Wed, Jul 20, 2011 at 5:41 PM, C M cmpyt...@gmail.com wrote: On Wed, Jul 20, 2011 at 7:24 PM, Buchholz, Greg gbuchh...@infiniacorp.com wrote: -Original Message- From: C M [mailto:cmpyt...@gmail.com

[Matplotlib-users] help with code for DurationFormatter

2011-07-20 Thread C M
A runnable code sample is attached. I'm trying to plot durations in time (sec to hours) on the y axis such that if you zoom, it changes the units and axis label appropriately. When run, it looks right. But, when I zoom on the first point, it is shown on the y axis at '0.20' minutes. I would

Re: [Matplotlib-users] simple question about locator every 0.5

2011-07-20 Thread C M
Try MultipleLocator: from matplotlib.ticker import MultipleLocator halflocator = MultipleLocator(base=0.5) ax.xaxis.set_major_locator(halflocator) etc. Thanks, that works for me. I didn't think I could use non-integers (0.5) because the docs said, Set a tick on every integer that is

Re: [Matplotlib-users] plot duration given format of '3:04:02.994000'

2011-07-18 Thread C M
On Mon, Jul 18, 2011 at 10:58 AM, Daniel Mader danielstefanma...@googlemail.com wrote: Hi, why don't you just parse the returned string? asdf = '3:04:02.994000' asdf = asdf.split(':') temp = asdf[-1].split('.') print asdf asdf.pop(-1) print asdf asdf.extend(temp) print asdf asdf =

[Matplotlib-users] plot duration given format of '3:04:02.994000'

2011-07-16 Thread C M
This a time duration in my database: '3:04:02.994000' (i.e., 3 hrs, 4 min, 2 sec and 994 microsec). It's a string. Is there a way to allow Matplotlib to interpret that directly as a duration of time? Thank you. --

Re: [Matplotlib-users] formatter for durations of varying units

2011-07-12 Thread C M
On Tue, Jul 12, 2011 at 3:15 AM, Maximilian Trescher fau...@trescher-it.de wrote: Hi, I want to pick a good (dynamic, for zooming) way to format the y axis. There are two issues: Does (1) seem like the right approach?  And for 2, is there already a formatter that is appropriate for this or

[Matplotlib-users] formatter for durations of varying units

2011-07-11 Thread C M
I need to make a dates (on x) vs. durations of time (on y) plots and need to have smart formatting for the y axis. My y data is in the database in the format: '0:00:02.994000', (that is, 2.9 seconds) and I'd like the y axis to be expressed in ticks of, e.g., 2 hrs, or 10 minutes, or 25 seconds,

Re: [Matplotlib-users] mpl newbie question...

2011-05-30 Thread C M
I do not know the first thing about Python language.But things are not going well That's not a but but an of course. How could they possibly go well already? It takes time to learn something. You will get there, bit by bit. and I do not want to use any other programs such as GNUplot

Re: [Matplotlib-users] another incorrectly clipped PNG in the gallery

2011-05-13 Thread C M
On Fri, May 13, 2011 at 6:23 AM, Pauli Virtanen p...@iki.fi wrote: Thu, 12 May 2011 15:16:43 -0400, C M wrote: [clip: installing Python modules] Is there a step-by-step method on the website that shows how to do this? Here: http://docs.python.org/install/index.html Thanks, but I guess I

Re: [Matplotlib-users] another incorrectly clipped PNG in the gallery

2011-05-13 Thread C M
On Wed, May 11, 2011 at 12:29 AM, Jae-Joon Lee lee.j.j...@gmail.com wrote: I think I fixed a similar bug at some point but I'm not sure if that is related with this. Are you using the *make_axes_area_auto_adjustable* from the current git master (check

Re: [Matplotlib-users] another incorrectly clipped PNG in the gallery

2011-05-12 Thread C M
On Thu, May 12, 2011 at 1:26 PM, Michael Droettboom md...@stsci.edu wrote: You can always get a tarball of the current git master by going here: https://github.com/matplotlib/matplotlib clicking on Download and choosing one of the download source options at the top of the popup box. Mike

Re: [Matplotlib-users] another incorrectly clipped PNG in the gallery

2011-05-12 Thread C M
On Thu, May 12, 2011 at 2:50 PM, Michael Droettboom md...@stsci.edu wrote: On 05/12/2011 02:34 PM, C M wrote: On Thu, May 12, 2011 at 1:26 PM, Michael Droettboommd...@stsci.edu  wrote: You can always get a tarball of the current git master by going here: https://github.com/matplotlib

Re: [Matplotlib-users] another incorrectly clipped PNG in the gallery

2011-05-11 Thread C M
On Wed, May 11, 2011 at 11:07 AM, C M cmpyt...@gmail.com wrote: On Wed, May 11, 2011 at 12:29 AM, Jae-Joon Lee lee.j.j...@gmail.com wrote: I think I fixed a similar bug at some point but I'm not sure if that is related with this. Are you using the *make_axes_area_auto_adjustable* from

Re: [Matplotlib-users] another incorrectly clipped PNG in the gallery

2011-05-09 Thread C M
On Thu, Sep 30, 2010 at 7:55 AM, Jae-Joon Lee lee.j.j...@gmail.com wrote: On Thu, Sep 23, 2010 at 10:31 AM, C M cmpyt...@gmail.com wrote: Until a more permanent solution is figured out, can anyone recommend any workarounds, even if they are a little clunky?  I'm embedding mpl plots in wxPython

Re: [Matplotlib-users] UserWarning: Attempting to set identical bottom==top

2011-05-06 Thread C M
On Fri, May 6, 2011 at 10:33 AM, Benjamin Root ben.r...@ou.edu wrote: On Thu, May 5, 2011 at 10:01 PM, C M cmpyt...@gmail.com wrote: Because you have a py2exe'ed program, I suspect that whoever packaged the program should be the one to modify that program to choose its axes limits more

Re: [Matplotlib-users] UserWarning: Attempting to set identical bottom==top

2011-05-05 Thread C M
On Thu, May 5, 2011 at 10:03 PM, C M cmpyt...@gmail.com wrote: On Thu, May 5, 2011 at 7:58 PM, Benjamin Root ben.r...@ou.edu wrote: On Sun, May 1, 2011 at 4:35 PM, C M cmpyt...@gmail.com wrote: I get this error and would like to know what to do to eliminate it and also what it means: C

Re: [Matplotlib-users] UserWarning: Attempting to set identical bottom==top

2011-05-05 Thread C M
Because you have a py2exe'ed program, I suspect that whoever packaged the program should be the one to modify that program to choose its axes limits more robustly in order to avoid the warning message. Maybe I have been unclear. I am the sole developer of this application, and I occasionally

[Matplotlib-users] get bboxes of bars in data coordinates

2011-03-28 Thread C M
I need to get the bboxes for time-range bars (matplotlib.patches.Rectangle objects) on a bar plot for a custom autoscaling function. Right now, I get them like this, where rectObj = a bar and bboxes = a list of bboxes: bboxes.append(rectObj.get_path().get_extents()) print 'bboxes is: ', bboxes

Re: [Matplotlib-users] get bboxes of bars in data coordinates

2011-03-28 Thread C M
I should add, I can see that (I think) this needs to use a transform to get it in data coordinates, because if I do this to each rectObj (each bar): trans = rectObj.get_patch_transform() print 'trans is: ', trans I get: trans is: BboxTransformTo(Bbox(array([[ 734189.52541214, 730844.

Re: [Matplotlib-users] get bboxes of bars in data coordinates

2011-03-28 Thread C M
On Mon, Mar 28, 2011 at 1:44 PM, C M cmpyt...@gmail.com wrote: I need to get the bboxes for time-range bars (matplotlib.patches.Rectangle objects) on a bar plot for a custom autoscaling function. Right now, I get them like this, where rectObj = a bar and bboxes = a list of bboxes

[Matplotlib-users] exclude lines from a loose_autoscale_view function

2011-03-23 Thread C M
I'm not sure if this is going to work to solve an issue I'm having, but I'd like to try it before asking a much more complex question. I have a function, loose_autoscale_view(), that is based on the autoscale_view function in mpl but allows margin arguments to push the margins out a bit more.

Re: [Matplotlib-users] onpick on a 2 y plot ( via twinx() ) seems to only allow picking of second axes's artists

2011-02-11 Thread C M
On Thu, Jan 20, 2011 at 4:44 AM, Stephan Markus zw...@web.de wrote: Hello! I am also using two axes in a plot and want to be able to pick the lines of both axes. So far I used MPL 0.99.3 and a button on my interface to change the z-order of the axes in order to be able to pick lines of the

Re: [Matplotlib-users] too many values to unpack with a bar chart

2011-01-27 Thread C M
Hi Paul, The reason you were getting that error is because unless you specify otherwise, ax.bar will make the bottom of the bars at 0 - which isn't an allowed date, hence the error. Change your bar line to this (I also added align='center', but you can remove it if you want): Aha, OK that

Re: [Matplotlib-users] too many values to unpack with a bar chart

2011-01-27 Thread C M
just make a numpy array out of your two lists, and you'll be able to subtract one from the other. import numpy as np top = np.array(top) bot = np.array(bot) Thank you, Paul. That worked and I'm now able to display bar charts. I appreciate it. Best, Che

[Matplotlib-users] too many values to unpack with a bar chart

2011-01-26 Thread C M
I usually do this for line graphs with markers: line, = self.subplot.plot_date(dates,data) along with some keywords to tweak the plot. I then add line to a dictionary to keep track of it: self.line_to_data_dict[line] = self.activity But today I tried this with a bar chart, just

Re: [Matplotlib-users] too many values to unpack with a bar chart

2011-01-26 Thread C M
Just a thought, are you trying out the new legend code? I don't know if I am or not. But these problems are prior to any code regarding the legend. Could you do a print of the type for bars? When I write it as just bars without the comma it is: bars type = type 'list' If I write it with

Re: [Matplotlib-users] too many values to unpack with a bar chart

2011-01-26 Thread C M
On Wed, Jan 26, 2011 at 9:16 PM, Jae-Joon Lee lee.j.j...@gmail.com wrote: On Thu, Jan 27, 2011 at 10:07 AM, C M cmpyt...@gmail.com wrote: I know the 2nd problem is that a dictionary cannot have a mutable object like a list as a key.  But previously, as I said, I was able to call line

Re: [Matplotlib-users] too many values to unpack with a bar chart

2011-01-26 Thread C M
3) I am getting just hammered with the following error *a lot* in date plotting lately: ValueError: ordinal must be = 1 OK, I made up a small runnable sample to show this with bar(). (Using code that someone else wrote[1]). This code runs when using plot_date(), but if you comment that out

[Matplotlib-users] floating bar chart?

2011-01-24 Thread C M
I looked through the gallery, but didn't see this one and am not sure how to create it. It would be a floating bar chart (or floating column chart), like what is seen here: http://peltiertech.com/Excel/pix1/BloodSugarFloater.gif Thanks, Che

Re: [Matplotlib-users] floating bar chart?

2011-01-24 Thread C M
On Mon, Jan 24, 2011 at 4:42 PM, Paul Ivanov pivanov...@gmail.com wrote: C M, on 2011-01-24 16:27,  wrote: I looked through the gallery, but didn't see this one and am not sure how to create it.  It would be a floating bar chart (or floating column chart), like what is seen here: http

Re: [Matplotlib-users] unable to point pick 2nd axis after upgrade to mpl 1.0

2010-12-14 Thread C M
It will work if you explicitly set its transform. star, = ax.plot([xdata[ind]], [ydata[ind]], '*', ms=40, mfc='y', mec='b', transform=thisline.get_transform()) JJ, thank you, this worked in my app as well. I also use the identity of the picked line in my code,

Re: [Matplotlib-users] another incorrectly clipped PNG in the gallery

2010-12-14 Thread C M
On Thu, Sep 30, 2010 at 7:55 AM, Jae-Joon Lee lee.j.j...@gmail.com wrote: On Thu, Sep 23, 2010 at 10:31 AM, C M cmpyt...@gmail.com wrote: Until a more permanent solution is figured out, can anyone recommend any workarounds, even if they are a little clunky? I'm embedding mpl plots

Re: [Matplotlib-users] unable to point pick 2nd axis after upgrade to mpl 1.0

2010-12-09 Thread C M
I have created a runnable sample app that demonstrates the problem Here is a much simpler 10 line sample that doesn't require wxPython and demonstrates the problem: you can't pick the red line. This seems like a bug in mpl 1.0. import matplotlib.pyplot as plt fig = plt.figure() ax =

[Matplotlib-users] unable to point pick 2nd axis after upgrade to mpl 1.0

2010-12-07 Thread C M
Hello, list. I have created a runnable sample app that demonstrates the problem (mentioned also in another thread) in the subject line. The sample is: - mpl 1.0 embedded in wxPython using wxAgg backend. - using plot() for simplicity, but see same issue if it is plot_date(). (I do date

[Matplotlib-users] what is line._invalid in matplotlib 1.0?

2010-12-05 Thread C M
Hello. I upgraded from about mpl 0.98.5 to 1.0, and this code, which worked in 0.98.5: if line._invalid: line.recache() now gives this error: AttributeError: 'Line2D' object has no attribute '_invalid' What is now (1.0) the right way to test whether a Line2D object is invalid?

Re: [Matplotlib-users] what is line._invalid in matplotlib 1.0?

2010-12-05 Thread C M
On Sun, Dec 5, 2010 at 9:33 PM, Jae-Joon Lee lee.j.j...@gmail.com wrote: Here is a modified version of the code. Note that since it uses non-public APIs, it may stop to work again in the future. According to your original post, you seem to want to pick up points only. I guess the better way

[Matplotlib-users] upgrade to 1.0 help

2010-12-03 Thread C M
Hello. I've decided to upgrade to matplotlib 1.0, but I'll need to fix a few problems that have come up. I was hoping I could get some help on this here. First thing is, I have a bit of point picker code that was written by JJ on this list some time back that has been working well. This is the

Re: [Matplotlib-users] upgrade to 1.0 help

2010-12-03 Thread C M
Hello. I've decided to upgrade to matplotlib 1.0, but I'll need to fix a few problems that have come up. I was hoping I could get some help on this here. Second problem: the grid background is gone despite these lines are not throwing any errors (here, self.subplot is an axis):

Re: [Matplotlib-users] upgrade to 1.0 help

2010-12-03 Thread C M
On Fri, Dec 3, 2010 at 8:10 PM, C M cmpyt...@gmail.com wrote: Hello. I've decided to upgrade to matplotlib 1.0, but I'll need to fix a few problems that have come up. I was hoping I could get some help on this here. Second problem: the grid background is gone despite these lines

Re: [Matplotlib-users] subclassing AutoDateFormatter correctly

2010-12-01 Thread C M
On Wed, Dec 1, 2010 at 12:28 AM, Ryan May rma...@gmail.com wrote: On Tue, Nov 30, 2010 at 7:00 PM, C M cmpyt...@gmail.com wrote: Thanks, Ryan. I've done that now. I use the OOP approach to matplotlib and embed it in wxPython, so my example uses that. I did not know how to apply

Re: [Matplotlib-users] subclassing AutoDateFormatter correctly

2010-11-30 Thread C M
On Sun, Nov 28, 2010 at 8:52 PM, C M cmpyt...@gmail.com wrote: How can I correctly subclass AutoDateFormatter and use it in my code? What I am doing is copying the code from matplotlib's AutoDateFormatter and changing the strings for how the dates are represented and making that a class

Re: [Matplotlib-users] subclassing AutoDateFormatter correctly

2010-11-30 Thread C M
On Tue, Nov 30, 2010 at 12:23 PM, Ryan May rma...@gmail.com wrote: On Tue, Nov 30, 2010 at 10:44 AM, C M cmpyt...@gmail.com wrote: On Sun, Nov 28, 2010 at 8:52 PM, C M cmpyt...@gmail.com wrote: How can I correctly subclass AutoDateFormatter and use it in my code? What I am doing

[Matplotlib-users] subclassing AutoDateFormatter correctly

2010-11-28 Thread C M
How can I correctly subclass AutoDateFormatter and use it in my code? What I am doing is copying the code from matplotlib's AutoDateFormatter and changing the strings for how the dates are represented and making that a class, MyAutoDateFormatter. AutoDateFormatter expects a locator, and I think

Re: [Matplotlib-users] date plot with two y axes...and some other things

2010-11-26 Thread C M
On Thu, Nov 18, 2010 at 12:59 PM, C M cmpyt...@gmail.com wrote: Goals:  date plot with two y axes (plotting completely different things)            point picking and point labeling            As many lines as user wants, all colored differently. Having some problems with this.  (matplotlib

[Matplotlib-users] date plot with two y axes...and some other things

2010-11-18 Thread C M
Goals: date plot with two y axes (plotting completely different things) point picking and point labeling As many lines as user wants, all colored differently. Having some problems with this. (matplotlib 0.98.5) 1) There is a known bug with twinx() and plot_date:

[Matplotlib-users] simpler example of embedding in wx

2010-09-25 Thread C M
I'd like to offer a simplest possible example for embedding in wxPython; significantly simpler and completely pared down compared to either of the two that are shown here: http://www.scipy.org/Matplotlib_figure_in_a_wx_panel but I don't have access to modify the page. Doesn't anyone on the list

Re: [Matplotlib-users] another incorrectly clipped PNG in the gallery

2010-09-22 Thread C M
On Wed, Sep 22, 2010 at 6:16 PM, Eric Firing efir...@hawaii.edu wrote: On 09/22/2010 10:11 AM, Russell Owen wrote: On Sep 22, 2010, at 11:16 AM, Benjamin Root wrote: On Wed, Sep 22, 2010 at 12:04 PM, Russell E. Owen ro...@uw.edu mailto:ro...@uw.edu wrote:     In article

Re: [Matplotlib-users] py2exe and matplotlib - Fonts: do I need them all?

2010-09-16 Thread C M
On Thu, Sep 16, 2010 at 6:33 PM, Carlos Grohmann carlos.grohm...@gmail.com wrote: Hello all, I'm new to py2exe but I managed to create a binary executable of my program. Now I'm experiencing on how to make the final size of the binary smaller. I already managed to cut about 15Mb by removing

Re: [Matplotlib-users] progress bar?

2010-06-28 Thread C M
On Mon, Jun 28, 2010 at 11:31 AM, Jim Vickroy jim.vick...@noaa.gov wrote: Carlos Grohmann wrote: I've been searching but coudn't find any example on how to add a progress bar to a wxpython+matplotlib app. I'd like my app to show a progress bar while some gridding and contouring are being

[Matplotlib-users] Fwd: install from svn on Linux not working for me

2010-04-19 Thread C M
-- Forwarded message -- From: C M cmpyt...@gmail.com Date: Mon, Apr 19, 2010 at 1:02 PM Subject: Re: [Matplotlib-users] install from svn on Linux not working for me To: Darren Dale dsdal...@gmail.com On Mon, Apr 19, 2010 at 8:02 AM, Darren Dale dsdal...@gmail.com wrote: On Mon

[Matplotlib-users] Fwd: install from svn on Linux not working for me

2010-04-19 Thread C M
-- Forwarded message -- From: C M cmpyt...@gmail.com Date: Mon, Apr 19, 2010 at 12:58 PM Subject: Re: [Matplotlib-users] install from svn on Linux not working for me To: LUK ShunTim lukshun...@gmail.com On Mon, Apr 19, 2010 at 4:30 AM, LUK ShunTim lukshun...@gmail.com wrote

Re: [Matplotlib-users] Fwd: install from svn on Linux not working for me

2010-04-19 Thread C M
On Mon, Apr 19, 2010 at 1:31 PM, Mauro Cavalcanti mauro...@gmail.com wrote: As I posted before, I ran across precisely these same errors when upgrading my Ubuntu box and the Python interpreter. You will need to install other dependencies as the installation log shows (gtk-2.0+, pygtk),

Re: [Matplotlib-users] Fwd: install from svn on Linux not working for me

2010-04-19 Thread C M
Michael and Darren (and others), I've used svn before to download pure Python code, but never to get anything that needed to be built. I'm fairly out to sea here, so thanks for the patience. When building from source, you also need the header files (*.h files) of all of matplotlib's

[Matplotlib-users] install from svn on Linux not working for me

2010-04-18 Thread C M
My goal is to just get the lastest svn version of matplotlib, or, if not that, just the 0.99 version, up and working on my Linux (Intrepid Ibex) computer.  I checked it matplotlib out from svn fine, and then, as per the webpage, did: cd matplotlib python setup.py install and that resulted in a

  1   2   >