obspy.core.util.misc.ptp

ptp(a, *args, **kwargs)[source]

Replacement for numpy.ndarray.ptp() and the corresponding method on MaskedArray objects which are being removed in numpy 2.0 Basically just makes sure we call the correct replacement function numpy put in place for regular and masked arrays.