pyinterp.geometry.cartesian.MultiPoint#
- class pyinterp.geometry.cartesian.MultiPoint(self, points: collections.abc.Sequence[pyinterp.core.geometry.cartesian.Point] | None = None)#
- class pyinterp.geometry.cartesian.MultiPoint(self, xs: numpy.ndarray[dtype=float64, shape=(*), writable=False], ys: numpy.ndarray[dtype=float64, shape=(*), writable=False])
Bases:
objectA collection of points in Cartesian coordinates.
Behaves like a Python container of Point objects.
Overloaded function.
__init__(self, points: collections.abc.Sequence[pyinterp.core.geometry.cartesian.Point] | None = None) -> None
Construct a multipoint from an optional sequence of points.
- Parameters:
points – Optional sequence of Point objects.
__init__(self, xs: numpy.ndarray[dtype=float64, shape=(*), writable=False], ys: numpy.ndarray[dtype=float64, shape=(*), writable=False]) -> None
Construct a multipoint from separate X and Y coordinate arrays.
- Parameters:
xs – X coordinate array.
ys – Y coordinate array.
Public Methods
append(self, pt)Append a point to the collection.
clear(self)Remove all points from the collection.
Special Methods
__bool__(self)Return True if not empty.
__eq__(self, other)Check if two multipoints are equal.
__getitem__(self, arg, /)Get point at index.
__getstate__(self)Return the state of the MultiPoint for pickling.
__iter__(self)Iterate over points.
__len__(self)Number of points.
__ne__(self, other)Check if two multipoints are not equal.
__new__(*args, **kwargs)__repr__(self)Return the official string representation of the MultiPoint.
__setitem__(self, idx, pt)Set point at index.
__setstate__(self, state)Restore the state of the MultiPoint from pickling.
__str__(self)Return the informal string representation of the MultiPoint.