mpl_toolkits.axes_grid1.axes_divider.Divider

class mpl_toolkits.axes_grid1.axes_divider.Divider(fig, pos, horizontal, vertical, aspect=None, anchor='C')[源代码]

基类:object

轴定位类。

分隔符用水平和垂直大小的列表初始化 (mpl_toolkits.axes_grid1.axes_size )在此基础上,一个给定的矩形区域将被划分。

这个 new_locator 方法然后创建一个可调用对象,该对象可以用作 axes_locator 轴的方向。

参数:
fig图形
pos4个浮点的元组

将被分割的矩形的位置。

水平的 : list of axes_size名单

水平分割的尺寸。

垂直的 : list of axes_size名单

垂直分割尺寸。

aspect布尔

整体矩形面积是否缩小,使水平比例尺和垂直比例尺的相对部分具有相同的比例尺。

anchor_'c'、's w'、's'、's e'、'e'、'n e'、'n'、'n w'、'w'

缩小矩形的放置,当 方面 是True。

__dict__ = mappingproxy({'__module__': 'mpl_toolkits.axes_grid1.axes_divider', '__doc__': '\n An Axes positioning class.\n\n The divider is initialized with lists of horizontal and vertical sizes\n (:mod:`mpl_toolkits.axes_grid1.axes_size`) based on which a given\n rectangular area will be divided.\n\n The `new_locator` method then creates a callable object\n that can be used as the *axes_locator* of the axes.\n ', '__init__': <function Divider.__init__>, 'get_horizontal_sizes': <function Divider.get_horizontal_sizes>, 'get_vertical_sizes': <function Divider.get_vertical_sizes>, 'get_vsize_hsize': <function Divider.get_vsize_hsize>, '_calc_k': <staticmethod object>, '_calc_offsets': <staticmethod object>, 'set_position': <function Divider.set_position>, 'get_position': <function Divider.get_position>, 'set_anchor': <function Divider.set_anchor>, 'get_anchor': <function Divider.get_anchor>, 'set_horizontal': <function Divider.set_horizontal>, 'get_horizontal': <function Divider.get_horizontal>, 'set_vertical': <function Divider.set_vertical>, 'get_vertical': <function Divider.get_vertical>, 'set_aspect': <function Divider.set_aspect>, 'get_aspect': <function Divider.get_aspect>, 'set_locator': <function Divider.set_locator>, 'get_locator': <function Divider.get_locator>, 'get_position_runtime': <function Divider.get_position_runtime>, 'locate': <function Divider.locate>, 'new_locator': <function Divider.new_locator>, 'append_size': <function Divider.append_size>, 'add_auto_adjustable_area': <function Divider.add_auto_adjustable_area>, '__dict__': <attribute '__dict__' of 'Divider' objects>, '__weakref__': <attribute '__weakref__' of 'Divider' objects>, '__annotations__': {}})
__init__(fig, pos, horizontal, vertical, aspect=None, anchor='C')[源代码]
参数:
fig图形
pos4个浮点的元组

将被分割的矩形的位置。

水平的 : list of axes_size名单

水平分割的尺寸。

垂直的 : list of axes_size名单

垂直分割尺寸。

aspect布尔

整体矩形面积是否缩小,使水平比例尺和垂直比例尺的相对部分具有相同的比例尺。

anchor_'c'、's w'、's'、's e'、'e'、'n e'、'n'、'n w'、'w'

缩小矩形的放置,当 方面 是True。

__module__ = 'mpl_toolkits.axes_grid1.axes_divider'
__weakref__

对象的弱引用列表(如果已定义)

add_auto_adjustable_area(use_axes, pad=0.1, adjust_dirs=None)[源代码]
append_size(position, size)[源代码]
get_anchor()[源代码]

回锚。

get_aspect()[源代码]

返回方面。

get_horizontal()[源代码]

返回水平大小。

get_horizontal_sizes(renderer)[源代码]
get_locator()[源代码]
get_position()[源代码]

返回矩形的位置。

get_position_runtime(ax, renderer)[源代码]
get_vertical()[源代码]

返回垂直大小。

get_vertical_sizes(renderer)[源代码]
get_vsize_hsize()[源代码]
locate(nx, ny, nx1=None, ny1=None, axes=None, renderer=None)[源代码]
参数:
NX,NX1利息

指定单元格列位置的整数。什么时候? nx1 一个也没有,一个也没有 nx -指定了第列。否则,柱的位置介于 nxnx1 (但除外) nx1 -指定了th列)。

纽约,纽约利息

等同于 nxnx1 ,但对于行位置。

axes
renderer
new_locator(nx, ny, nx1=None, ny1=None)[源代码]

返回一个新的 AxesLocator 对于指定单元格。

参数:
NX,NX1利息

指定单元格列位置的整数。什么时候? nx1 一个也没有,一个也没有 nx -指定了第列。否则,柱的位置介于 nxnx1 (但除外) nx1 -指定了th列)。

纽约,纽约利息

等同于 nxnx1 ,但对于行位置。

set_anchor(anchor)[源代码]
参数:
anchor_'c'、's w'、's'、's e'、'e'、'n e'、'n'、'n w'、'w'

锚定位置

价值 描述
“C” 中心
“西南” 左下角
“S” 底部
“SE” 右下
“e” 正确的
“NE” 右上方
“N” 顶部
“西北” 左上角
“W” 左边
set_aspect(aspect=False)[源代码]
参数:
aspect布尔
set_horizontal(h)[源代码]
参数:
h : list of axes_size名单

水平分割尺寸

set_locator(_locator)[源代码]
set_position(pos)[源代码]

设置矩形的位置。

参数:
pos4个浮点的元组

将被分割的矩形的位置

set_vertical(v)[源代码]
参数:
v : list of axes_size名单

垂直分割尺寸

使用实例 mpl_toolkits.axes_grid1.axes_divider.Divider