get_peaks(x, y, ignore_threshold = 0, span = 5, strict = TRUE, x_unit = "", x_digits = 3)
get_valleys(x, y, ignore_threshold = 0, span = 5, strict = TRUE, x_unit = "", x_digits = 3)
span
centered at that element. For example, a value of 3 means that a peak is
bigger than both of its neighbors.find_peaks
,
peaks
, valleys
with(sun.spct, get_peaks(w.length, s.e.irrad))
with(sun.spct, get_valleys(w.length, s.e.irrad))
Run the code above in your browser using DataLab