hilow | R Documentation |
Search for Extrema along time series
hilow(y)
y |
time series |
LIST:
hi |
indexes to peaks |
lo |
indexes to valleys |
Jonathan M. Lees<jonathan.lees.edu>
peaks
ex <- seq(from=0, to=4*pi, length = 200)
y <- sin(ex)
plot(ex, y, type='l')
peakval <- hilow(y)
abline(v=ex[peakval$hi], col='green')
abline(v=ex[peakval$lo], col='red')
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.