on 07/31/2008 03:20 PM Economics Guy wrote:
I have a large data set where one of the columns needs be a unique
identifier (ID) for each row. However for a few of the rows they have
the same ID. What I need to do is randomly draw one of the rows and
keep it in the data frame and drop all the other
I have a large data set where one of the columns needs be a unique
identifier (ID) for each row. However for a few of the rows they have
the same ID. What I need to do is randomly draw one of the rows and
keep it in the data frame and drop all the others which have the same
ID.
For example:
v1 <-
2 matches
Mail list logo