gaitmap.utils.array_handling.find_local_minima_with_distance#

gaitmap.utils.array_handling.find_local_minima_with_distance(data: ndarray, threshold: float | None = None, **kwargs) ndarray[source]#

Find local minima using scipy’s find_peaks function.

Because find_peaks is designed to find local maxima, the data multiplied by -1. The same is true for the threshold value, if supplied.

Parameters:
data

The datastream. The default axis to search for the minima is 0. To search for minima this is multiplied by -1 before passing to find_peaks

threshold

The maximal allowed value for the minimum. - threshold is passed to the height argument of find_peaks

kwargs

Directly passed to find_peaks