On Thu, May 5, 2011 at 9:04 PM, C M <cmpyt...@gmail.com> wrote:

> 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:\Python25\lib\site-packages\matplotlib\axes.py:2571:
> >>> UserWarning: Attempting to set identical bottom==top results
> >>> in singular transformations; automatically expanding.
> >>> bottom=0, top=0 + 'bottom=%s, top=%s') % (bottom, top))
> >>>
> >>> This is with Matplotlib 1.0.0.
> >>>
> >>> Thank you,
> >>> Che
> >>>
> >>
> > I have seen this happen when the plot is set to use the limits of the
> data
> > to guide the axes limits, but the data being displayed is either vertical
> or
> > horizontal.
>
> What do you mean by the data being vertical or horizontal?  I can get
> this error with a single point that is plotted on a time vs. values
> plot.
>
>
Or even a single point.  In other words, if the bounding box encompassing
the data being plotted can be reduced to a 1 or 0 dimensional
representation, then matplotlib will auto-pad this so that the rest of
matplotlib won't crash.



> >  It isn't a huge issue as the code is automatically padding the
> > axes to make take the plot out of "flat world".
>
> The problem is, when I use a py2exe'd app this error occurs and the
> user sees a message to see the log file for the error. I don't want
> that at all.  It's a bad user experience.
>

The warning message is important because it is usually an indication that
the program is doing something wrong.  If you (and by "you", I mean the
program) might be plotting a single point or something that can be reduced
to 1 or 0 dimensions, then you should not have the axes automatically set
its limits from the data without pads.

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.

Unless the other developers feel differently, I am against suppressing this
warning message.

I hope that makes things clearer.
Ben Root
------------------------------------------------------------------------------
WhatsUp Gold - Download Free Network Management Software
The most intuitive, comprehensive, and cost-effective network 
management toolset available today.  Delivers lowest initial 
acquisition cost and overall TCO of any competing solution.
http://p.sf.net/sfu/whatsupgold-sd
_______________________________________________
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users

Reply via email to