code: def set_matplotlib_close(close=True):
      """Set whether the inline backend closes all figures automatically or not.
  
      By default, the inline backend used in the IPython Notebook will close all
      matplotlib figures automatically after each cell is run. This means that
      plots in different cells won't interfere. Sometimes, you may want to make
      a plot in one cell and then refine it in later cells. This can be accomplished
      by::
  
          In [1]: set_matplotlib_close(False)
  
      To set this in your config files use the following::
  
          c.InlineBackend.close_figures = False
  
      Parameters
      ----------
      close : bool
          Should all matplotlib figures be automatically closed after each cell is
          run?
      """
      cfg = InlineBackend.instance()
      cfg.close_figures = close
  
imports: import matplotlib
  from matplotlib import colors
  from matplotlib.backends import backend_agg
  from matplotlib.backends.backend_agg import FigureCanvasAgg
  from matplotlib._pylab_helpers import Gcf
  from matplotlib.figure import Figure
  from IPython.core.interactiveshell import InteractiveShell
  from IPython.core.getipython import get_ipython
  from IPython.core.pylabtools import select_figure_formats
  from IPython.display import display
  from .config import InlineBackend
label_desc: Use image node_id 11 for calling a global function with example usage: set_matplotlib_close(close) without return types