add_axes_at_origin

Plotter.add_axes_at_origin(x_color=None, y_color=None, z_color=None, xlabel='X', ylabel='Y', zlabel='Z', line_width=2, labels_off=False)

Add axes actor at origin.

Parameters
x_colorstr or 3 item sequence, optional

The color of the x axes arrow.

y_colorstr or 3 item sequence, optional

The color of the y axes arrow.

z_colorstr or 3 item sequence, optional

The color of the z axes arrow.

xlabelstr, optional

The label of the x axes arrow.

ylabelstr, optional

The label of the y axes arrow.

zlabelstr, optional

The label of the z axes arrow.

line_widthint, optional

Width of the arrows.

labels_offbool, optional

Disables the label text when True.

Returns
vtk.vtkAxesActor

Actor of the axes.

Examples

>>> import pyvista
>>> pl = pyvista.Plotter()
>>> _ = pl.add_mesh(pyvista.Sphere(center=(2, 0, 0)), color='r')
>>> _ = pl.add_mesh(pyvista.Sphere(center=(0, 2, 0)), color='g')
>>> _ = pl.add_mesh(pyvista.Sphere(center=(0, 0, 2)), color='b')
>>> _ = pl.add_axes_at_origin()
>>> pl.show()
../../../_images/pyvista-Plotter-add_axes_at_origin-1_00_00.png