skrf.time.find_n_peaks¶
- skrf.time.find_n_peaks(x, n, thres=0.9, **kwargs)[source]¶
Find a given number of peaks in a signal.
- Parameters:
x (npy.ndarray) – signal
n (int) – number of peaks to search for
thres (float, optional) – threshold, default is 0.9
**kwargs (optional keyword arguments passed to
indexes()
) –
- Returns:
peak_idxs – List containing the numeric indexes of the peaks that were detected
- Return type:
list of int
- Raises:
ValueError – If no peaks are found.