View source: R/correct_peaks.R
shift_peaks | R Documentation |
Helper function for correct_peaks. Return the shifted peaks to local maxima or minima within a radius.
shift_peaks(sig, peak_inds, search_radius = 20, peak_up = TRUE)
sig |
The 1d signal vector |
peak_inds |
vector of the original peak indices |
search_radius |
The integer radius within which the original peaks may be shifted. |
peak_up |
: Whether the expected peak direction is up. TRUE/FALSE |
shifted_peak_inds vector of the corrected peak indices.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.