Revision: 4194
http://matplotlib.svn.sourceforge.net/matplotlib/?rev=4194&view=rev
Author: mdboom
Date: 2007-11-09 12:14:29 -0800 (Fri, 09 Nov 2007)
Log Message:
-----------
Fix exception plotting an errorbar graph with only two data points.
Modified Paths:
--------------
trunk/matplotlib/lib/matplotlib/axes.py
Modified: trunk/matplotlib/lib/matplotlib/axes.py
===================================================================
--- trunk/matplotlib/lib/matplotlib/axes.py 2007-11-09 20:00:39 UTC (rev
4193)
+++ trunk/matplotlib/lib/matplotlib/axes.py 2007-11-09 20:14:29 UTC (rev
4194)
@@ -3717,7 +3717,7 @@
plot_kw['mew']=kwargs['mew']
if xerr is not None:
- if iterable(xerr) and len(xerr)==2:
+ if iterable(xerr) and len(xerr)==2 and iterable(xerr[0]) and
iterable(xerr[1]):
# using list comps rather than arrays to preserve units
left = [thisx-thiserr for (thisx, thiserr) in
cbook.safezip(x,xerr[0])]
right = [thisx+thiserr for (thisx, thiserr) in
cbook.safezip(x,xerr[1])]
@@ -3751,7 +3751,7 @@
caplines.extend( self.plot(right, y, 'k|', **plot_kw) )
if yerr is not None:
- if iterable(yerr) and len(yerr)==2:
+ if iterable(yerr) and len(yerr)==2 and iterable(yerr[0]) and
iterable(yerr[1]):
# using list comps rather than arrays to preserve units
lower = [thisy-thiserr for (thisy, thiserr) in
cbook.safezip(y,yerr[0])]
upper = [thisy+thiserr for (thisy, thiserr) in
cbook.safezip(y,yerr[1])]
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
Matplotlib-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/matplotlib-checkins