.. _sphx_glr_gallery_subplots_axes_and_figures_subplot_toolbar.py: =============== Subplot Toolbar =============== Matplotlib has a toolbar available for adjusting suplot spacing. .. rst-class:: sphx-glr-horizontal * .. image:: /gallery/subplots_axes_and_figures/images/sphx_glr_subplot_toolbar_001.png :scale: 47 * .. image:: /gallery/subplots_axes_and_figures/images/sphx_glr_subplot_toolbar_002.png :scale: 47 .. code-block:: python import matplotlib.pyplot as plt import numpy as np fig, axs = plt.subplots(2, 2) axs[0, 0].imshow(np.random.random((100, 100))) axs[0, 1].imshow(np.random.random((100, 100))) axs[1, 0].imshow(np.random.random((100, 100))) axs[1, 1].imshow(np.random.random((100, 100))) plt.subplot_tool() plt.show() **Total running time of the script:** ( 0 minutes 0.305 seconds) .. only :: html .. container:: sphx-glr-footer .. container:: sphx-glr-download :download:`Download Python source code: subplot_toolbar.py ` .. container:: sphx-glr-download :download:`Download Jupyter notebook: subplot_toolbar.ipynb ` .. only:: html .. rst-class:: sphx-glr-signature `Gallery generated by Sphinx-Gallery `_