Re: [R] Selecting unique values

2011-07-26 Thread Daniel Malter
Steven's solution is great, but it will only work if the rows are really duplicates. If the data frame contains another variable whose values vary, it will not work because then the rows are obviously unique. df<-data.frame(df,value=rnorm(11)) unique(df) You would then have to make a decision, w

Re: [R] Selecting unique values

2011-07-25 Thread Steven Kennedy
use unique() df <- data.frame(Species_name=c(rep('Abies concolor',4),rep('Accipiter cooperi',7)), Longitude=c(-106.601, -106.493, -106.489, -106.496, -119.688, -119.792, -118.797,-77.38333,-77.38333,-75.99153,-75.99153), Latitude=c(35.868, 35.9682, 35.892, 35.85