skspatial.objects.Plane.project_vector

Plane.project_vector(vector: Union[ndarray, Sequence]) Vector[source]

Project a vector onto the plane.

Parameters
vectorarray_like

Input vector.

Returns
Vector

Projection of the vector onto the plane.

Examples

>>> from skspatial.objects import Plane
>>> plane = Plane([0, 4, 0], [0, 1, 1])
>>> plane.project_vector([2, 4, 8])
Vector([ 2., -2.,  2.])