diff --git a/lib/matplotlib/axes/_axes.py b/lib/matplotlib/axes/_axes.py index 3c05ddd915d8..692254f0151e 100644 --- a/lib/matplotlib/axes/_axes.py +++ b/lib/matplotlib/axes/_axes.py @@ -2956,8 +2956,8 @@ def extract_err(err, data): fe = safe_first_element(err) if not ((len(err) == len(data) and not (iterable(fe) and len(fe) > 1))): - raise ValueError("err must be a scalar, the same " - "dimensions as x, or 2xN.") + raise ValueError("err must be [ scalar | N, Nx1 " + "or 2xN array-like ]") # using list comps rather than arrays to preserve units low = [thisx - thiserr for (thisx, thiserr) in cbook.safezip(data, err)]