<divid="unreleased-message"> You are reading an old version of the documentation (v1.5.3). For the latest version see <ahref="https://matplotlib.org/stable/api/tight_layout_api.html">https://matplotlib.org/stable/api/tight_layout_api.html</a></div>
<codeclass="descclassname">matplotlib.tight_layout.</code><codeclass="descname">auto_adjust_subplotpars</code><spanclass="sig-paren">(</span><em>fig</em>, <em>renderer</em>, <em>nrows_ncols</em>, <em>num1num2_list</em>, <em>subplot_list</em>, <em>ax_bbox_list=None</em>, <em>pad=1.08</em>, <em>h_pad=None</em>, <em>w_pad=None</em>, <em>rect=None</em><spanclass="sig-paren">)</span><aclass="headerlink" href="#matplotlib.tight_layout.auto_adjust_subplotpars" title="Permalink to this definition">¶</a></dt>
<dd><p>Return a dictionary of subplot parameters so that spacing between
subplots are adjusted. Note that this function ignore geometry
information of subplot itself, but uses what is given by
<em>nrows_ncols</em> and <em>num1num2_list</em> parameteres. Also, the results could be
incorrect if some subplots have <codeclass="docutils literal"><spanclass="pre">adjustable=datalim</span></code>.</p>
<p>Parameters:</p>
<dlclass="docutils">
<dt>nrows_ncols</dt>
<dd>number of rows and number of columns of the grid.</dd>
<dt>num1num2_list</dt>
<dd>list of numbers specifying the area occupied by the subplot</dd>
<dt>subplot_list</dt>
<dd>list of subplots that will be used to calcuate optimal subplot_params.</dd>
<dt>pad</dt>
<spanclass="classifier-delimiter">:</span><spanclass="classifier">float</span><dd>padding between the figure edge and the edges of subplots, as a fraction
of the font-size.</dd>
<dt>h_pad, w_pad</dt>
<spanclass="classifier-delimiter">:</span><spanclass="classifier">float</span><dd><dlclass="first last docutils">
<dt>padding (height/width) between edges of adjacent subplots.</dt>
<dd>Defaults to <codeclass="xref py py-obj docutils literal"><spanclass="pre">pad_inches</span></code>.</dd>
</dl>
</dd>
<dt>rect</dt>
<dd>[left, bottom, right, top] in normalized (0, 1) figure coordinates.</dd>
</dl>
</dd></dl>
<dlclass="function">
<dtid="matplotlib.tight_layout.get_renderer">
<codeclass="descclassname">matplotlib.tight_layout.</code><codeclass="descname">get_renderer</code><spanclass="sig-paren">(</span><em>fig</em><spanclass="sig-paren">)</span><aclass="headerlink" href="#matplotlib.tight_layout.get_renderer" title="Permalink to this definition">¶</a></dt>
<codeclass="descclassname">matplotlib.tight_layout.</code><codeclass="descname">get_subplotspec_list</code><spanclass="sig-paren">(</span><em>axes_list</em>, <em>grid_spec=None</em><spanclass="sig-paren">)</span><aclass="headerlink" href="#matplotlib.tight_layout.get_subplotspec_list" title="Permalink to this definition">¶</a></dt>
<dd><p>Return a list of subplotspec from the given list of axes. For an
instance of axes that does not support subplotspec, None is
inserted in the list.</p>
<p>If grid_spec is given, None is inserted for those not from
<codeclass="descclassname">matplotlib.tight_layout.</code><codeclass="descname">get_tight_layout_figure</code><spanclass="sig-paren">(</span><em>fig</em>, <em>axes_list</em>, <em>subplotspec_list</em>, <em>renderer</em>, <em>pad=1.08</em>, <em>h_pad=None</em>, <em>w_pad=None</em>, <em>rect=None</em><spanclass="sig-paren">)</span><aclass="headerlink" href="#matplotlib.tight_layout.get_tight_layout_figure" title="Permalink to this definition">¶</a></dt>
<dd><p>Return subplot parameters for tight-layouted-figure with specified
padding.</p>
<p>Parameters:</p>
<blockquote>
<div><p><em>fig</em> : figure instance</p>
<p><em>axes_list</em> : a list of axes</p>
<dlclass="docutils">
<dt><em>subplotspec_list</em></dt>
<spanclass="classifier-delimiter">:</span><spanclass="classifier">a list of subplotspec associated with each</span><dd>axes in axes_list</dd>
</dl>
<p><em>renderer</em> : renderer instance</p>
<dlclass="docutils">
<dt><em>pad</em></dt>
<spanclass="classifier-delimiter">:</span><spanclass="classifier">float</span><dd>padding between the figure edge and the edges of subplots,
as a fraction of the font-size.</dd>
<dt><em>h_pad</em>, <em>w_pad</em></dt>
<spanclass="classifier-delimiter">:</span><spanclass="classifier">float</span><dd>padding (height/width) between edges of adjacent subplots.
Defaults to <codeclass="xref py py-obj docutils literal"><spanclass="pre">pad_inches</span></code>.</dd>
<dt><em>rect</em></dt>
<spanclass="classifier-delimiter">:</span><spanclass="classifier">if rect is given, it is interpreted as a rectangle</span><dd>(left, bottom, right, top) in the normalized figure
coordinate that the whole subplots area (including
labels) will fit into. Default is (0, 0, 1, 1).</dd>