Hi Christos, It's... more or less the same thing. I was looking for a matrix.to.matrix.run.me() function :)
Cheers, Adrian On Sunday 21 January 2007 00:56, Christos Hatzis wrote: > Here is a slightly more compact version of your function which might run > faster (I did not test timings) since it does not use the sum: > > apply(mat2, 1, function(x) which(apply(mat1, 1, function(y) all(x == y)) == > TRUE)) > > -Christos -- Adrian Dusa Romanian Social Data Archive 1, Schitu Magureanu Bd 050025 Bucharest sector 5 Romania Tel./Fax: +40 21 3126618 \ +40 21 3120210 / int.101 ______________________________________________ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.