[R] I need a very specific unique like function and I don't know even how to properly call this

madr madrazel at interia.pl
Mon Nov 22 21:53:41 CET 2010


consider this matrix:

      [,1] [,2]
 [1,]    3   7
 [2,]    6   5
 [3,]    7   5
 [4,]    3   5
 [5,]    7   5
 [6,]    5   5
 [7,]    8   4
 [8,]    2   4
 [9,]    7   4
[10,]    0   6

I need to delete all rows where column 2 above and below has the same value,
so the effect would be:

      [,1] [,2]
 [1,]    3   7
 [2,]    6   5
 [6,]    5   5
 [7,]    8   4
 [9,]    7   4
[10,]    0   6

is there a built in function for that kind of operation or I must write one
from scratch ?
Is there a name for that kind of operation ?
-- 
View this message in context: http://r.789695.n4.nabble.com/I-need-a-very-specific-unique-like-function-and-I-don-t-know-even-how-to-properly-call-this-tp3054427p3054427.html
Sent from the R help mailing list archive at Nabble.com.



More information about the R-help mailing list