[R] R equivalent for Splus "peaks"
mark at myatt.demon.co.uk
Sat Jun 16 12:27:56 CEST 2001
Matthew Wiener <mcw at ln.nimh.nih.gov> writes:
>Does anyone have an equivalent to Splus "peaks", which finds local maxima
>(with locality defined by a parameter "span")? I thought I'd check
>whether anyone has done it already before trying to put something together
Not my solution but one I kept from, I think, Brian Ripley:
z <- embed(series, span)
result_max.col(z) == 1 + span %/% 2
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch
More information about the R-help