[R] a silly question on index of a matrix

From: zhihua li <lzhtom_at_hotmail.com>
Date: Wed 26 Oct 2005 - 11:52:32 EST

Hi netters,

This is probably a silly question,but I can't find the answer after searching the R-help archives online. ok, I have a matrix. I know there is a "10" somewhere in it. Now I want to
know the index of the element "10" in this matrix. That is, if X[i,j]=10, I want to know
i and j. Is there a R function to do this? Just like the "find" function in matlab.

Thanks all!

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 Received on Wed Oct 26 12:03:33 2005

This archive was generated by hypermail 2.1.8 : Fri 03 Mar 2006 - 03:40:47 EST