{ } Raw JSON

bundles / scipy 1.17.1 / scipy / signal / _peak_finding_utils / _peak_prominences

cython_function_or_method

scipy.signal._peak_finding_utils:_peak_prominences

Signature

def   _peak_prominences ( x peaks wlen )

Summary

Calculate the prominence of each peak in a signal.

Parameters

x : ndarray

A signal with peaks.

peaks : ndarray

Indices of peaks in x.

wlen : np.intp

A window length in samples (see peak_prominences) which is rounded up to the nearest odd integer. If smaller than 2 the entire signal x is used.

Returns

prominences : ndarray

The calculated prominences for each peak in peaks.

left_bases, right_bases : ndarray

The peaks' bases as indices in x to the left and right of each peak.

Raises

: ValueError

If a value in peaks is an invalid index for x.

Warns

: PeakPropertyWarning

If a prominence of 0 was calculated for any peak.

Notes

This is the inner function to peak_prominences.

Aliases

  • scipy.signal._peak_finding._peak_prominences