Spec-Zone.ru › Matplotlib

matplotlib.axes.Axes.set_position

Axes.set_position(pos, which='both')[source]

Set the Axes position.

Axes have two position attributes. The 'original' position is the position allocated for the Axes. The 'active' position is the position the Axes is actually drawn at. These positions are usually the same unless a fixed aspect is set to the Axes. See Axes.set_aspect for details.

Parameters:
pos[left, bottom, width, height] or Bbox

The new position of the Axes in Figure coordinates.

which{'both', 'active', 'original'}, default: 'both'

Determines which position variables to change.

See also

matplotlib.transforms.Bbox.from_bounds
matplotlib.transforms.Bbox.from_extents

Examples using matplotlib.axes.Axes.set_position

Contour Demo

Contour Demo

© 2012–2026 Matplotlib Development Team. All rights reserved.
Licensed under the Matplotlib License Agreement.
https://matplotlib.org/stable/api/_as_gen/matplotlib.axes.Axes.set_position.html

Spec-Zone.ru

Настройки Оффлайн Что нового Помощь О нас
Spec-Zone .ru
спецификации, руководства, описания, API