diff --git a/lib/matplotlib/cbook/__init__.py b/lib/matplotlib/cbook/__init__.py index 34c6ddb8610d..e057c66f8f34 100644 --- a/lib/matplotlib/cbook/__init__.py +++ b/lib/matplotlib/cbook/__init__.py @@ -132,9 +132,9 @@ class CallbackRegistry: for a set of signals and callbacks: >>> def oneat(x): - ... print('eat', x) + ... print('eat', x) >>> def ondrink(x): - ... print('drink', x) + ... print('drink', x) >>> from matplotlib.cbook import CallbackRegistry >>> callbacks = CallbackRegistry() @@ -1905,7 +1905,7 @@ def _array_perimeter(arr): Examples -------- - >>> i, j = np.ogrid[:3,:4] + >>> i, j = np.ogrid[:3, :4] >>> a = i*10 + j >>> a array([[ 0, 1, 2, 3], @@ -1949,7 +1949,7 @@ def _unfold(arr, axis, size, step): Examples -------- - >>> i, j = np.ogrid[:3,:7] + >>> i, j = np.ogrid[:3, :7] >>> a = i*10 + j >>> a array([[ 0, 1, 2, 3, 4, 5, 6], diff --git a/lib/matplotlib/widgets.py b/lib/matplotlib/widgets.py index 1bc62bdd8b18..807e9d360071 100644 --- a/lib/matplotlib/widgets.py +++ b/lib/matplotlib/widgets.py @@ -2908,10 +2908,9 @@ class RectangleSelector(_SelectorWidget): ... print(erelease.xdata, erelease.ydata) >>> props = dict(facecolor='blue', alpha=0.5) >>> rect = mwidgets.RectangleSelector(ax, onselect, interactive=True, - props=props) + ... props=props) >>> fig.show() - - >>> selector.add_state('square') + >>> rect.add_state('square') See also: :doc:`/gallery/widgets/rectangle_selector` """ pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy