slice_orthogonal

PolyData.slice_orthogonal(x=None, y=None, z=None, generate_triangles=False, contour=False, progress_bar=False)

Create three orthogonal slices through the dataset on the three cartesian planes.

Yields a MutliBlock dataset of the three slices.

Parameters
xfloat, optional

The X location of the YZ slice.

yfloat, optional

The Y location of the XZ slice.

zfloat, optional

The Z location of the XY slice.

generate_trianglesbool, optional

If this is enabled (False by default), the output will be triangles. Otherwise the output will be the intersection polygons.

contourbool, optional

If True, apply a contour filter after slicing.

progress_barbool, optional

Display a progress bar to indicate progress.

Returns
pyvista.PolyData

Sliced dataset.

Examples

Slice the random hills dataset with three orthogonal planes.

>>> from pyvista import examples
>>> hills = examples.load_random_hills()
>>> slices = hills.slice_orthogonal(contour=False)
>>> slices.plot(line_width=5)
../../../_images/pyvista-PolyData-slice_orthogonal-1_00_00.png

See Slicing for more examples using this filter.