Skip to content
Prev 39714 / 63421 Next

duplicates() function

On 08/04/2011 11:08 AM, Joshua Ulrich wrote:
That's a nice solution for vectors.  Unfortunately for me, I have a 
matrix (which duplicated() handles by checking whole rows).  So a better 
example that I should have posted would be

x <-  cbind(1, c(9,7,9,3,7) )

and I'd still like the same output
[1] FALSE FALSE  TRUE FALSE TRUE
[1] NA NA  1 NA  2


Duncan Murdoch