skspatial.objects.Points.are_coplanar

Points.are_coplanar(**kwargs) bool[source]

Check if the points are all contained in one plane.

Parameters:
kwargsdict, optional

Additional keywords passed to numpy.linalg.matrix_rank()

Returns:
bool

True if points are coplanar; false otherwise.

Examples

>>> from skspatial.objects import Points
>>> Points([[1, 2], [9, -18], [12, 4], [2, 1]]).are_coplanar()
True
>>> Points([[1, 2], [9, -18], [12, 4], [2, 2]]).are_coplanar()
True
>>> Points([[0, 0, 0], [1, 0, 0], [0, 1, 0], [0, 0, 1]]).are_coplanar()
False