Not entirely sure what you need. This gives data greater than a certain level:
z <- c(23,4,56,7,99) z[z>20] or z[z>=median(z)] This extracts points that are larger than the ones on either side: zz <- c(-Inf,z,-Inf) z[diff(sign(diff(zz)))<0] --- Date: Wed, 26 Nov 2003 19:08:50 -0300 (ART) From: <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Subject: [R] multiple peaks in data frame Hello, it wanted to know how I can extract of a dates frame the values peaks according to an interval that I establish. For example if dates are: 1 23 2 4 3 56 4 7 5 99 6 33 extract the date i wanted to divide into intervals of 2 an d to take alone the numbers 23, 56 and 99 of those 3 intervals. Thanks Ruben ______________________________________________ [EMAIL PROTECTED] mailing list https://www.stat.math.ethz.ch/mailman/listinfo/r-help
