mpl_toolkits.axes_grid1.axes_grid.Grid
- class mpl_toolkits.axes_grid1.axes_grid.Grid(fig, rect, nrows_ncols, n_axes=None, direction='row', axes_pad=0.02, *, share_all=False, , , , ,
Bases: object
A grid of Axes.
In Matplotlib, the Axes location (and size) is specified in normalized figure coordinates. This may not be ideal for images that needs to be displayed with a given aspect ratio; for example, it is difficult to display multiple images of a same size with some fixed padding between them. AxesGrid can be used in such case.
A flat list of Axes. Note that you can also access this directly from the grid. The following is equivalent
grid[i] == grid.axes_all[i]
len(grid) == len(grid.axes_all)
A 2D list of Axes where the first index is the column. This results
in the usage pattern grid.axes_column[col][row].
A 2D list of Axes where the first index is the row. This results
in the usage pattern grid.axes_row[row][col].
The Axes in the lower left corner.
Number of Axes in the grid.
FigureThe parent figure.
SubplotSpecThe axes position, as a (left, bottom, width, height) tuple,
as a three-digit subplot position code (e.g., (1, 2, 1) or
), or as a .
Return the aspect of the SubplotDivider.
Return the axes padding.
Padding (horizontal pad, vertical pad) in inches.
Return the number of rows and columns of the grid as (nrows, ncols).
[Deprecated]
Set the aspect of the SubplotDivider.
Set the padding between the axes.
The padding (horizontal pad, vertical pad) in inches.
Define which axes have tick labels.
The label mode:
"L": All axes on the left column get vertical tick labels; all axes on the bottom row get horizontal tick labels.
"1": Only the bottom left axes is labelled.
"all": All axes are labelled.
"keep": Do not do anything.
mpl_toolkits.axes_grid1.axes_grid.GridNumber of rows and columns in the grid.
If given, only the first n_axes axes in the grid are created.
Whether axes are created in row-major ("row by row") or
column-major order ("column by column"). This also affects the
order in which axes are accessed using indexing (grid[index]).
Padding or (horizontal padding, vertical padding) between axes, in inches.
Whether all axes share their x- and y-axis. Overrides share_x and share_y.
Whether all axes of a column share their x-axis.
Whether all axes of a row share their y-axis.
Determines which axes will get tick labels:
"L": All axes on the left column get vertical tick labels; all axes on the bottom row get horizontal tick labels.
"1": Only the bottom left axes is labelled.
"all": All axes are labelled.
"keep": Do not do anything.
matplotlib.axes.Axes, default: mpl_axes.AxesThe type of Axes to create.
Whether the axes aspect ratio follows the aspect ratio of the data limits.