mpl.figure

The figure module provides the top-level Artist, the Figure, which contains all the plot elements. The following classes are defined

SubplotParams
control the default spacing of the subplots
Figure
top level container for all plot elements

Functions

allow_rasterization(draw) Decorator for Artist.draw method.
figaspect(arg) Create a figure with specified aspect ratio.
get_projection_names() Get a list of acceptable projection names.
iterable(obj) return true if obj is iterable
process_projection_requirements(figure, ...) Handle the args/kwargs to for add_axes/add_subplot/gca,
subplot_class_factory([axes_class])

Classes

Affine2D([matrix]) A mutable 2D affine transformation.
Artist() Abstract base class for someone who renders into a FigureCanvas.
Axes(fig, rect[, axisbg, frameon, sharex, ...]) The Axes contains most of the figure elements: Axis, Tick, Line2D, Text, Polygon, etc., and sets the coordinate system.
AxesStack() Specialization of the Stack to handle all tracking of Axes in a Figure.
Bbox(points, **kwargs) A mutable bounding box.
BboxTransformTo(boxout, **kwargs) BboxTransformTo is a transformation that linearly
BlockingKeyMouseInput(fig) Class that creates a callable object to retrieve a single mouse or
BlockingMouseInput(fig[, mouse_add, ...]) Class that creates a callable object to retrieve mouse clicks in a blocking way.
Figure([figsize, dpi, facecolor, edgecolor, ...]) The Figure instance supports callbacks through a callbacks attribute which is a matplotlib.cbook.CallbackRegistry instance.
FigureImage(fig[, cmap, norm, offsetx, ...])
Legend(parent, handles, labels[, loc, ...]) Place a legend on the axes at location loc.
Rectangle(xy, width, height[, angle]) Draw a rectangle with lower left at xy = (x, y) with specified width and height.
Stack([default]) Implement a stack where elements can be pushed on and you can move back and forth.
SubplotBase(fig, *args, **kwargs) Base class for subplots, which are Axes instances with additional methods to facilitate generating and manipulating a set of Axes within a figure.
SubplotParams([left, bottom, right, top, ...]) A class to hold the parameters for a subplot
Text([x, y, text, color, verticalalignment, ...]) Handle storing and drawing of text in window or data coordinates.
TransformedBbox(bbox, transform, **kwargs) A Bbox that is automatically transformed by a given transform.
itemgetter itemgetter(item, ...) –> itemgetter object

Exceptions

NonGuiException