[Matplotlib] 기능모음
||| matplotlib.pyplot.tight_layout
matplotlib.pyplot.tight_layout (*, pad=1.08, h_pad=None, w_pad=None, rect=None)
Adjust the padding between and around subplots.
To exclude an artist on the Axes from the bounding box calculation that determines the subplot parameters (i.e. legend, or annotation), set a.set_in_layout(False) for that artist.
Parameters:padfloat, default: 1.08
Padding between the figure edge and the edges of subplots, as a fraction of the font size.
h_pad, w_padfloat, default: pad
Padding (height/width) between edges of adjacent subplots, as a fraction of the font size.
recttuple (left, bottom, right, top), default: (0, 0, 1, 1)
A rectangle in normalized figure coordinates into which the whole subplots area (including labels) will fit.
||| ax. twinx
Create a twin Axes sharing the X axis.
Create a new Axes with an invisible x-axis and an independent y-axis positioned opposite to the original one (i.e. at right). The x-axis autoscale setting will be inherited from the original Axes. To ensure that the tick marks of both y-axes align
Returns:Axes
The newly created Axes instance
||| matplotlib.pyplot.tight_layout
matplotlib.pyplot.tight_layout(*, pad=1.08, h_pad=None, w_pad=None, rect=None)
Adjust the padding between and around subplots.
To exclude an artist on the Axes from the bounding box calculation that determines the subplot parameters (i.e. legend, or annotation), set a.set_in_layout(False) for that artist.
Parameters:padfloat, default: 1.08
Padding between the figure edge and the edges of subplots, as a fraction of the font size.
h_pad, w_padfloat, default: pad
Padding (height/width) between edges of adjacent subplots, as a fraction of the font size.
recttuple (left, bottom, right, top), default: (0, 0, 1, 1)
A rectangle in normalized figure coordinates into which the whole subplots area (including labels) will fit.
참고자료
Matplotlib - 공식문서
https://matplotlib.org/stable/api/_as_gen/matplotlib.pyplot.figure.html