image
imagewidth (px)
75
2.22k
code
stringlengths
300
16.2k
example_id
stringlengths
28
79
figure_index
int64
0
26
figure_name
stringclasses
28 values
title
stringlengths
38
94
example_page_url
stringlengths
61
195
source_url
stringlengths
80
111
source_relpath
stringlengths
6
37
category_hint
stringclasses
24 values
status
stringclasses
1 value
num_figures
int64
1
27
error
null
""" ========================= Date precision and epochs ========================= Matplotlib can handle `.datetime` objects and `numpy.datetime64` objects using a unit converter that recognizes these dates and converts them to floating point numbers. Before Matplotlib 3.3, the default for this conversion returns a fl...
stable__gallery__ticks__date_precision_and_epochs
0
figure_000.png
Date precision and epochs — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/ticks/date_precision_and_epochs.html#sphx-glr-download-gallery-ticks-date-precision-and-epochs-py
https://matplotlib.org/stable/_downloads/586a88c62e8a2d883ea392b25f0e62a9/date_precision_and_epochs.py
date_precision_and_epochs.py
ticks
ok
2
null
""" ============ Dollar ticks ============ Use a format string to prepend dollar signs on y-axis labels. .. redirect-from:: /gallery/pyplots/dollar_ticks """ import matplotlib.pyplot as plt import numpy as np # Fixing random state for reproducibility np.random.seed(19680801) fig, ax = plt.subplots() ax.plot(100*np...
stable__gallery__ticks__dollar_ticks
0
figure_000.png
Dollar ticks — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/ticks/dollar_ticks.html#sphx-glr-download-gallery-ticks-dollar-ticks-py
https://matplotlib.org/stable/_downloads/c42c8ac5c413d3d2897f606da8b90ccd/dollar_ticks.py
dollar_ticks.py
ticks
ok
1
null
""" =================================================== SI prefixed offsets and natural order of magnitudes =================================================== `matplotlib.ticker.EngFormatter` is capable of computing a natural offset for your axis data, and presenting it with a standard SI prefix automatically calcula...
stable__gallery__ticks__engformatter_offset
0
figure_000.png
SI prefixed offsets and natural order of magnitudes — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/ticks/engformatter_offset.html#sphx-glr-download-gallery-ticks-engformatter-offset-py
https://matplotlib.org/stable/_downloads/0626606af53131a40fb15598b3954d64/engformatter_offset.py
engformatter_offset.py
ticks
ok
1
null
""" ========================= Fig Axes Customize Simple ========================= Customize the background, labels and ticks of a simple plot. .. redirect-from:: /gallery/pyplots/fig_axes_customize_simple """ import matplotlib.pyplot as plt # %% # `.pyplot.figure` creates a `matplotlib.figure.Figure` instance. fig...
stable__gallery__ticks__fig_axes_customize_simple
0
figure_000.png
Fig Axes Customize Simple — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/ticks/fig_axes_customize_simple.html#sphx-glr-download-gallery-ticks-fig-axes-customize-simple-py
https://matplotlib.org/stable/_downloads/c2319cc152ca13b70dc936f2c7792dc2/fig_axes_customize_simple.py
fig_axes_customize_simple.py
ticks
ok
1
null
r""" ===================== Major and minor ticks ===================== Demonstrate how to use major and minor tickers. The two relevant classes are `.Locator`\s and `.Formatter`\s. Locators determine where the ticks are, and formatters control the formatting of tick labels. Minor ticks are off by default (using `.N...
stable__gallery__ticks__major_minor_demo
0
figure_000.png
Major and minor ticks — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/ticks/major_minor_demo.html#sphx-glr-download-gallery-ticks-major-minor-demo-py
https://matplotlib.org/stable/_downloads/4ad72df52615cfce120da1981d41d969/major_minor_demo.py
major_minor_demo.py
ticks
ok
2
null
""" ========================= Multilevel (nested) ticks ========================= Sometimes we want another level of tick labels on an axis, perhaps to indicate a grouping of the ticks. Matplotlib does not provide an automated way to do this, but it is relatively straightforward to annotate below the main axis. Thes...
stable__gallery__ticks__multilevel_ticks
0
figure_000.png
Multilevel (nested) ticks — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/ticks/multilevel_ticks.html#sphx-glr-download-gallery-ticks-multilevel-ticks-py
https://matplotlib.org/stable/_downloads/3525cc5d1774b69b18d51894d36a5368/multilevel_ticks.py
multilevel_ticks.py
ticks
ok
3
null
""" ========================= Multilevel (nested) ticks ========================= Sometimes we want another level of tick labels on an axis, perhaps to indicate a grouping of the ticks. Matplotlib does not provide an automated way to do this, but it is relatively straightforward to annotate below the main axis. Thes...
stable__gallery__ticks__multilevel_ticks
1
figure_001.png
Multilevel (nested) ticks — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/ticks/multilevel_ticks.html#sphx-glr-download-gallery-ticks-multilevel-ticks-py
https://matplotlib.org/stable/_downloads/3525cc5d1774b69b18d51894d36a5368/multilevel_ticks.py
multilevel_ticks.py
ticks
ok
3
null
""" ========================= Multilevel (nested) ticks ========================= Sometimes we want another level of tick labels on an axis, perhaps to indicate a grouping of the ticks. Matplotlib does not provide an automated way to do this, but it is relatively straightforward to annotate below the main axis. Thes...
stable__gallery__ticks__multilevel_ticks
2
figure_002.png
Multilevel (nested) ticks — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/ticks/multilevel_ticks.html#sphx-glr-download-gallery-ticks-multilevel-ticks-py
https://matplotlib.org/stable/_downloads/3525cc5d1774b69b18d51894d36a5368/multilevel_ticks.py
multilevel_ticks.py
ticks
ok
3
null
""" ========================== The default tick formatter ========================== By default, tick labels are formatted using a `.ScalarFormatter`, which can be configured via `~.axes.Axes.ticklabel_format`. This example illustrates some possible configurations: - Default. - ``useMathText=True``: Fancy formatting...
stable__gallery__ticks__scalarformatter
0
figure_000.png
The default tick formatter — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/ticks/scalarformatter.html#the-default-tick-formatter
https://matplotlib.org/stable/_downloads/d09144c4107ab96d8a55006e711872ef/scalarformatter.py
scalarformatter.py
ticks
ok
1
null
""" =============== Tick formatters =============== Tick formatters define how the numeric value associated with a tick on an axis is formatted as a string. This example illustrates the usage and effect of the most common formatters. The tick format is configured via the function `~.Axis.set_major_formatter` or `~.A...
stable__gallery__ticks__tick-formatters
0
figure_000.png
Tick formatters — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/ticks/tick-formatters.html#tick-formatters
https://matplotlib.org/stable/_downloads/982150f6f72db2a6042ea9a81adacb7e/tick-formatters.py
tick-formatters.py
ticks
ok
1
null
""" ============= Tick locators ============= Tick locators define the position of the ticks. This example illustrates the usage and effect of the most common locators. """ import matplotlib.pyplot as plt import numpy as np import matplotlib.ticker as ticker def setup(ax, title): """Set up common parameters f...
stable__gallery__ticks__tick-locators
0
figure_000.png
Tick locators — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/ticks/tick-locators.html#tick-locators
https://matplotlib.org/stable/_downloads/7dd629c030892b8738bc4c5e86dc6736/tick-locators.py
tick-locators.py
ticks
ok
1
null
""" ============================================ Set default y-axis tick labels on the right ============================================ We can use :rc:`ytick.labelright`, :rc:`ytick.right`, :rc:`ytick.labelleft`, and :rc:`ytick.left` to control where on the axes ticks and their labels appear. These properties can al...
stable__gallery__ticks__tick_label_right
0
figure_000.png
Set default y-axis tick labels on the right — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/ticks/tick_label_right.html#sphx-glr-download-gallery-ticks-tick-label-right-py
https://matplotlib.org/stable/_downloads/e30931f9cdd67ddca47f3c2a7ec762c7/tick_label_right.py
tick_label_right.py
ticks
ok
1
null
""" ========================================= Setting tick labels from a list of values ========================================= Using `.Axes.set_xticks` causes the tick labels to be set on the currently chosen ticks. However, you may want to allow matplotlib to dynamically choose the number of ticks and their spacin...
stable__gallery__ticks__tick_labels_from_values
0
figure_000.png
Setting tick labels from a list of values — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/ticks/tick_labels_from_values.html#sphx-glr-download-gallery-ticks-tick-labels-from-values-py
https://matplotlib.org/stable/_downloads/2b7917f5efd95d93b11c49f7a421baeb/tick_labels_from_values.py
tick_labels_from_values.py
ticks
ok
1
null
""" ================================== Move x-axis tick labels to the top ================================== `~.axes.Axes.tick_params` can be used to configure the ticks. *top* and *labeltop* control the visibility tick lines and labels at the top x-axis. To move x-axis ticks from bottom to top, we have to activate th...
stable__gallery__ticks__tick_xlabel_top
0
figure_000.png
Move x-axis tick labels to the top — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/ticks/tick_xlabel_top.html#sphx-glr-download-gallery-ticks-tick-xlabel-top-py
https://matplotlib.org/stable/_downloads/3963661c0214fe8afa4aa8c5aa77218e/tick_xlabel_top.py
tick_xlabel_top.py
ticks
ok
1
null
""" =================== Rotated tick labels =================== """ import matplotlib.pyplot as plt x = [1, 2, 3, 4] y = [1, 4, 9, 6] labels = ['Frogs', 'Hogs', 'Bogs', 'Slogs'] fig, ax = plt.subplots() ax.plot(x, y) # A tick label rotation can be set using Axes.tick_params. ax.tick_params("y", rotation=45) # Altern...
stable__gallery__ticks__ticklabels_rotation
0
figure_000.png
Rotated tick labels — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/ticks/ticklabels_rotation.html#sphx-glr-download-gallery-ticks-ticklabels-rotation-py
https://matplotlib.org/stable/_downloads/6bf1f86ac14b705a7352333c341c3b82/ticklabels_rotation.py
ticklabels_rotation.py
ticks
ok
1
null
""" ===================== Fixing too many ticks ===================== One common cause for unexpected tick behavior is passing a list of strings instead of numbers or datetime objects. This can easily happen without notice when reading in a comma-delimited text file. Matplotlib treats lists of strings as *categorical*...
stable__gallery__ticks__ticks_too_many
0
figure_000.png
Fixing too many ticks — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/ticks/ticks_too_many.html#sphx-glr-download-gallery-ticks-ticks-too-many-py
https://matplotlib.org/stable/_downloads/bf27e73826393797c5d906c0afefb14d/ticks_too_many.py
ticks_too_many.py
ticks
ok
3
null
""" ===================== Fixing too many ticks ===================== One common cause for unexpected tick behavior is passing a list of strings instead of numbers or datetime objects. This can easily happen without notice when reading in a comma-delimited text file. Matplotlib treats lists of strings as *categorical*...
stable__gallery__ticks__ticks_too_many
1
figure_001.png
Fixing too many ticks — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/ticks/ticks_too_many.html#sphx-glr-download-gallery-ticks-ticks-too-many-py
https://matplotlib.org/stable/_downloads/bf27e73826393797c5d906c0afefb14d/ticks_too_many.py
ticks_too_many.py
ticks
ok
3
null
""" ===================== Fixing too many ticks ===================== One common cause for unexpected tick behavior is passing a list of strings instead of numbers or datetime objects. This can easily happen without notice when reading in a comma-delimited text file. Matplotlib treats lists of strings as *categorical*...
stable__gallery__ticks__ticks_too_many
2
figure_002.png
Fixing too many ticks — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/ticks/ticks_too_many.html#sphx-glr-download-gallery-ticks-ticks-too-many-py
https://matplotlib.org/stable/_downloads/bf27e73826393797c5d906c0afefb14d/ticks_too_many.py
ticks_too_many.py
ticks
ok
3
null
""" ========== Evans test ========== A mockup "Foo" units class which supports conversion and different tick formatting depending on the "unit". Here the "unit" is just a scalar conversion factor, but this example shows that Matplotlib is entirely agnostic to what kind of units client packages use. """ import matplo...
stable__gallery__units__evans_test
0
figure_000.png
Evans test — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/units/evans_test.html#sphx-glr-download-gallery-units-evans-test-py
https://matplotlib.org/stable/_downloads/dd53845e9b4ff2a1c978459bd05b003e/evans_test.py
evans_test.py
units
ok
1
null
""" ============= SVG Histogram ============= Demonstrate how to create an interactive histogram, in which bars are hidden or shown by clicking on legend markers. The interactivity is encoded in ecmascript (javascript) and inserted in the SVG code in a post-processing step. To render the image, open it in a web brows...
stable__gallery__user_interfaces__svg_histogram_sgskip
0
figure_000.png
SVG Histogram — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/user_interfaces/svg_histogram_sgskip.html#svg-histogram
https://matplotlib.org/stable/_downloads/dbbfc471cc5f69a894fff87dbd2bbf19/svg_histogram_sgskip.py
svg_histogram_sgskip.py
user_interfaces
ok
1
null
""" =========== SVG Tooltip =========== This example shows how to create a tooltip that will show up when hovering over a matplotlib patch. Although it is possible to create the tooltip from CSS or javascript, here we create it in matplotlib and simply toggle its visibility on when hovering over the patch. This appro...
stable__gallery__user_interfaces__svg_tooltip_sgskip
0
figure_000.png
SVG Tooltip — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/user_interfaces/svg_tooltip_sgskip.html#svg-tooltip
https://matplotlib.org/stable/_downloads/b1d72b68be293db9dab6f77187a06e16/svg_tooltip_sgskip.py
svg_tooltip_sgskip.py
user_interfaces
ok
1
null
r""" ================ Nested GridSpecs ================ This example demonstrates the use of nested `.GridSpec`\s. """ import matplotlib.pyplot as plt import numpy as np def squiggle_xy(a, b, c, d): i = np.arange(0.0, 2*np.pi, 0.05) return np.sin(i*a)*np.cos(i*b), np.sin(i*c)*np.cos(i*d) fig = plt.figure(...
stable__gallery__userdemo__demo_gridspec06
0
figure_000.png
Nested GridSpecs — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/userdemo/demo_gridspec06.html#sphx-glr-download-gallery-userdemo-demo-gridspec06-py
https://matplotlib.org/stable/_downloads/82f0e1275a063ac077b19c2162ab5453/demo_gridspec06.py
demo_gridspec06.py
userdemo
ok
1
null
""" =============== Simple Legend01 =============== """ import matplotlib.pyplot as plt fig = plt.figure() ax = fig.add_subplot(211) ax.plot([1, 2, 3], label="test1") ax.plot([3, 2, 1], label="test2") # Place a legend above this subplot, expanding itself to # fully use the given bounding box. ax.legend(bbox_to_ancho...
stable__gallery__userdemo__simple_legend01
0
figure_000.png
Simple Legend01 — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/userdemo/simple_legend01.html#sphx-glr-download-gallery-userdemo-simple-legend01-py
https://matplotlib.org/stable/_downloads/4e35546e054302909f70da22e48450ec/simple_legend01.py
simple_legend01.py
userdemo
ok
1
null
""" =============== Simple Legend02 =============== """ import matplotlib.pyplot as plt fig, ax = plt.subplots() line1, = ax.plot([1, 2, 3], label="Line 1", linestyle='--') line2, = ax.plot([3, 2, 1], label="Line 2", linewidth=4) # Create a legend for the first line. first_legend = ax.legend(handles=[line1], loc='u...
stable__gallery__userdemo__simple_legend02
0
figure_000.png
Simple Legend02 — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/userdemo/simple_legend02.html#sphx-glr-download-gallery-userdemo-simple-legend02-py
https://matplotlib.org/stable/_downloads/a28765be19887476469c03569a192293/simple_legend02.py
simple_legend02.py
userdemo
ok
1
null
""" ================ Annotated cursor ================ Display a data cursor including a text box, which shows the plot point close to the mouse pointer. The new cursor inherits from `~matplotlib.widgets.Cursor` and demonstrates the creation of new widgets and their event callbacks. See also the :doc:`cross hair cur...
stable__gallery__widgets__annotated_cursor
0
figure_000.png
Annotated cursor — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/widgets/annotated_cursor.html#trouble-with-non-biunique-functions
https://matplotlib.org/stable/_downloads/49afaefa9a6da5dbbf0e8baa083505f3/annotated_cursor.py
annotated_cursor.py
widgets
ok
2
null
""" ======= Buttons ======= Constructing a simple button GUI to modify a sine wave. The ``next`` and ``previous`` button widget helps visualize the wave with new frequencies. """ import matplotlib.pyplot as plt import numpy as np from matplotlib.widgets import Button freqs = np.arange(2, 20, 3) fig, ax = plt.subp...
stable__gallery__widgets__buttons
0
figure_000.png
Buttons — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/widgets/buttons.html#sphx-glr-download-gallery-widgets-buttons-py
https://matplotlib.org/stable/_downloads/1396177ce1d23fee4cbc40e2635021b2/buttons.py
buttons.py
widgets
ok
1
null
""" ============= Check buttons ============= Turning visual elements on and off with check buttons. This program shows the use of `.CheckButtons` which is similar to check boxes. There are 3 different sine waves shown, and we can choose which waves are displayed with the check buttons. Check buttons may be styled u...
stable__gallery__widgets__check_buttons
0
figure_000.png
Check buttons — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/widgets/check_buttons.html#sphx-glr-download-gallery-widgets-check-buttons-py
https://matplotlib.org/stable/_downloads/c08881ff905bac0ced64da581a650859/check_buttons.py
check_buttons.py
widgets
ok
1
null
""" ====== Cursor ====== """ import matplotlib.pyplot as plt import numpy as np from matplotlib.widgets import Cursor # Fixing random state for reproducibility np.random.seed(19680801) fig, ax = plt.subplots(figsize=(8, 6)) x, y = 4*(np.random.rand(2, 100) - .5) ax.plot(x, y, 'o') ax.set_xlim(-2, 2) ax.set_ylim(-2...
stable__gallery__widgets__cursor
0
figure_000.png
Cursor — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/widgets/cursor.html#sphx-glr-download-gallery-widgets-cursor-py
https://matplotlib.org/stable/_downloads/b9ef6f84d8dd108e5700bbf0e163014a/cursor.py
cursor.py
widgets
ok
1
null
""" ============== Lasso Selector ============== Interactively selecting data points with the lasso tool. This examples plots a scatter plot. You can then select a few points by drawing a lasso loop around the points on the graph. To draw, just click on the graph, hold, and drag it around the points you need to selec...
stable__gallery__widgets__lasso_selector_demo_sgskip
0
figure_000.png
Lasso Selector — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/widgets/lasso_selector_demo_sgskip.html#sphx-glr-download-gallery-widgets-lasso-selector-demo-sgskip-py
https://matplotlib.org/stable/_downloads/cff0c57a9f43e62cbd6e2ee706caa49e/lasso_selector_demo_sgskip.py
lasso_selector_demo_sgskip.py
widgets
ok
1
null
""" ==== Menu ==== Using texts to construct a simple menu. """ from dataclasses import dataclass import matplotlib.pyplot as plt import matplotlib.artist as artist import matplotlib.patches as patches from matplotlib.typing import ColorType @dataclass class ItemProperties: fontsize: float = 14 labelcolor:...
stable__gallery__widgets__menu
0
figure_000.png
Menu — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/widgets/menu.html#sphx-glr-download-gallery-widgets-menu-py
https://matplotlib.org/stable/_downloads/1d795d2dbb3742249ef04dbbdc524568/menu.py
menu.py
widgets
ok
1
null
""" ============ Mouse Cursor ============ This example sets an alternative cursor on a figure canvas. Note, this is an interactive example, and must be run to see the effect. """ import matplotlib.pyplot as plt from matplotlib.backend_tools import Cursors fig, axs = plt.subplots(len(Cursors), figsize=(6, len(Curs...
stable__gallery__widgets__mouse_cursor
0
figure_000.png
Mouse Cursor — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/widgets/mouse_cursor.html#sphx-glr-download-gallery-widgets-mouse-cursor-py
https://matplotlib.org/stable/_downloads/ab3f838084c7ddafe92dade4d05a6f67/mouse_cursor.py
mouse_cursor.py
widgets
ok
1
null
""" =========== Multicursor =========== Showing a cursor on multiple plots simultaneously. This example generates three Axes split over two different figures. On hovering the cursor over data in one subplot, the values of that datapoint are shown in all Axes. """ import matplotlib.pyplot as plt import numpy as np ...
stable__gallery__widgets__multicursor
0
figure_000.png
Multicursor — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/widgets/multicursor.html#sphx-glr-download-gallery-widgets-multicursor-py
https://matplotlib.org/stable/_downloads/515d3050c92b37baf0ab9a6a1511df37/multicursor.py
multicursor.py
widgets
ok
2
null
""" =========== Multicursor =========== Showing a cursor on multiple plots simultaneously. This example generates three Axes split over two different figures. On hovering the cursor over data in one subplot, the values of that datapoint are shown in all Axes. """ import matplotlib.pyplot as plt import numpy as np ...
stable__gallery__widgets__multicursor
1
figure_001.png
Multicursor — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/widgets/multicursor.html#sphx-glr-download-gallery-widgets-multicursor-py
https://matplotlib.org/stable/_downloads/515d3050c92b37baf0ab9a6a1511df37/multicursor.py
multicursor.py
widgets
ok
2
null
""" ======================================================= Select indices from a collection using polygon selector ======================================================= Shows how one can select indices of a polygon interactively. """ import numpy as np from matplotlib.path import Path from matplotlib.widgets impo...
stable__gallery__widgets__polygon_selector_demo
0
figure_000.png
Select indices from a collection using polygon selector — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/widgets/polygon_selector_demo.html#sphx-glr-download-gallery-widgets-polygon-selector-demo-py
https://matplotlib.org/stable/_downloads/e01448737f71ce88ac3f2177a351c1de/polygon_selector_demo.py
polygon_selector_demo.py
widgets
ok
1
null
""" ================ Polygon Selector ================ Shows how to create a polygon programmatically or interactively """ import matplotlib.pyplot as plt from matplotlib.widgets import PolygonSelector # %% # # To create the polygon programmatically fig, ax = plt.subplots() fig.show() selector = PolygonSelector(ax...
stable__gallery__widgets__polygon_selector_simple
0
figure_000.png
Polygon Selector — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/widgets/polygon_selector_simple.html#sphx-glr-download-gallery-widgets-polygon-selector-simple-py
https://matplotlib.org/stable/_downloads/82a3b4570f59acc5a372cb7be136c952/polygon_selector_simple.py
polygon_selector_simple.py
widgets
ok
2
null
""" ================ Polygon Selector ================ Shows how to create a polygon programmatically or interactively """ import matplotlib.pyplot as plt from matplotlib.widgets import PolygonSelector # %% # # To create the polygon programmatically fig, ax = plt.subplots() fig.show() selector = PolygonSelector(ax...
stable__gallery__widgets__polygon_selector_simple
1
figure_001.png
Polygon Selector — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/widgets/polygon_selector_simple.html#sphx-glr-download-gallery-widgets-polygon-selector-simple-py
https://matplotlib.org/stable/_downloads/82a3b4570f59acc5a372cb7be136c952/polygon_selector_simple.py
polygon_selector_simple.py
widgets
ok
2
null
""" ============= Radio Buttons ============= Using radio buttons to choose properties of your plot. Radio buttons let you choose between multiple options in a visualization. In this case, the buttons let the user choose one of the three different sine waves to be shown in the plot. Radio buttons may be styled using...
stable__gallery__widgets__radio_buttons
0
figure_000.png
Radio Buttons — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/widgets/radio_buttons.html#sphx-glr-download-gallery-widgets-radio-buttons-py
https://matplotlib.org/stable/_downloads/51785ae53b1786fb0ed5b01f90362232/radio_buttons.py
radio_buttons.py
widgets
ok
1
null
""" ================================= Image scaling using a RangeSlider ================================= Using the RangeSlider widget to control the thresholding of an image. The RangeSlider widget can be used similarly to the `.widgets.Slider` widget. The major difference is that RangeSlider's ``val`` attribute is ...
stable__gallery__widgets__range_slider
0
figure_000.png
Image scaling using a RangeSlider — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/widgets/range_slider.html#sphx-glr-download-gallery-widgets-range-slider-py
https://matplotlib.org/stable/_downloads/5d09fa7f28b450731d677f4d2e54e675/range_slider.py
range_slider.py
widgets
ok
1
null
""" =============================== Rectangle and ellipse selectors =============================== Click somewhere, move the mouse, and release the mouse button. `.RectangleSelector` and `.EllipseSelector` draw a rectangle or an ellipse from the initial click position to the current mouse position (within the same ax...
stable__gallery__widgets__rectangle_selector
0
figure_000.png
Rectangle and ellipse selectors — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/widgets/rectangle_selector.html#sphx-glr-download-gallery-widgets-rectangle-selector-py
https://matplotlib.org/stable/_downloads/6fd8c57479cccb2b7f96c0257b4200d1/rectangle_selector.py
rectangle_selector.py
widgets
ok
1
null
""" ====== Slider ====== In this example, sliders are used to control the frequency and amplitude of a sine wave. See :doc:`/gallery/widgets/slider_snap_demo` for an example of having the ``Slider`` snap to discrete values. See :doc:`/gallery/widgets/range_slider` for an example of using a ``RangeSlider`` to define ...
stable__gallery__widgets__slider_demo
0
figure_000.png
Slider — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/widgets/slider_demo.html#sphx-glr-download-gallery-widgets-slider-demo-py
https://matplotlib.org/stable/_downloads/34827ebbd80a7be269c66280f4b258ee/slider_demo.py
slider_demo.py
widgets
ok
1
null
""" =============================== Snap sliders to discrete values =============================== You can snap slider values to discrete values using the ``valstep`` argument. In this example the Freq slider is constrained to be multiples of pi, and the Amp slider uses an array as the ``valstep`` argument to more d...
stable__gallery__widgets__slider_snap_demo
0
figure_000.png
Snap sliders to discrete values — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/widgets/slider_snap_demo.html#sphx-glr-download-gallery-widgets-slider-snap-demo-py
https://matplotlib.org/stable/_downloads/68c95e07ab61a26521daa7870bba11fe/slider_snap_demo.py
slider_snap_demo.py
widgets
ok
1
null
""" ============= Span Selector ============= The `.SpanSelector` is a mouse widget that enables selecting a range on an axis. Here, an x-range can be selected on the upper axis; a detailed view of the selected range is then plotted on the lower axis. .. note:: If the SpanSelector object is garbage collected yo...
stable__gallery__widgets__span_selector
0
figure_000.png
Span Selector — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/widgets/span_selector.html#sphx-glr-download-gallery-widgets-span-selector-py
https://matplotlib.org/stable/_downloads/b6df01615e62198a6e6b651c4b836b36/span_selector.py
span_selector.py
widgets
ok
1
null
""" ======= Textbox ======= The Textbox widget lets users interactively provide text input, including formulas. In this example, the plot is updated using the `.on_submit` method. This method triggers the execution of the *submit* function when the user presses enter in the textbox or leaves the textbox. Note: The `...
stable__gallery__widgets__textbox
0
figure_000.png
Textbox — Matplotlib 3.10.8 documentation
https://matplotlib.org/stable/gallery/widgets/textbox.html#textbox
https://matplotlib.org/stable/_downloads/9af1076c2fab3dbe816bfbf4cfe1b9f5/textbox.py
textbox.py
widgets
ok
1
null