hello all, I have a dataset where the subjects are duplicated. How do I subset such that I can get only I row/subject.
aa<-c(1,1,2,2,3,3,4,4,5,5,6,6) bb<-c(56,56,33,33,53,53,20,20,63,63,9,9) cc<-data.frame(aa,bb) I would like to subset df(cc) such that I can get aa bb 1 56 2 33 3 53 4 20 5 63 6 9 I know this should be fairly easy but I can't figure how to do it in a dataframe and keep all my columns Thanks ______________________________________________ [email protected] 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.
