Locates samples where the first derivative crosses zero from
positive to non-positive AND the prior slope magnitude exceeds
threshold_factor * max(|dx|).
Usage
morie_dsp_derivative_detect(x, fs = 1, threshold_factor = 0.5)
Arguments
- x
Numeric vector.
- fs
Sampling frequency (Hz). Default 1.
- threshold_factor
Slope threshold fraction. Default 0.5.
Value
Integer vector of peak indices.
References
Rangayyan & Krishnan (2015), Ch. 4, sec. 4.3.