mpl_toolkits.mplot3d.axes3d.Axes3D.set_box_aspect#

Axes3D.set_box_aspect(aspect,*,zoom=1)[source]#

Set the Axes box aspect.

The box aspect is the ratio of height to width in displayunits for each face of the box when viewed perpendicular tothat face. This is not to be confused with the data aspect (seeset_aspect). The default ratios are 4:4:3 (x:y:z).

To simulate having equal aspect in data space, set the boxaspect to match your data range in each dimension.

zoom controls the overall size of the Axes3D in the figure.

Parameters:
aspect3-tuple of floats or None

Changes the physical dimensions of the Axes3D, such that the ratioof the axis lengths in display units is x:y:z.If None, defaults to (4, 4, 3).

zoomfloat, default: 1

Control overall size of the Axes3D in the figure. Must be > 0.

Examples usingmpl_toolkits.mplot3d.axes3d.Axes3D.set_box_aspect#

3D box surface plot

3D box surface plot