Displaying 1 result from an estimated 1 matches for "samps_work".
2009 Dec 17
1
Remove duplicates from a data frame but with some special requirements
Hi all.
So I have a data frame with multiple columns/variables. The first variable
is a major sample name for which there are some sub-samples. Currently I
have used the following command to remove the duplicates:
Samps_working<-Samps[-c(which(duplicated(Samps$ESR_Ref_edit))),]
This removes all of the duplicated sample rows.
However, I just realised that, of course, this removes the first observation
of each duplicated set. However, I wish to retain any that have the code
"Y" in another variable Samps$L...