[R] duplicate values

Oliver Bandel oliver at first.in-berlin.de
Sun Nov 16 19:21:15 CET 2008


Antje Nöthlich <antno <at> web.de> writes:

[...]
> Now for the whole dataframe i would like to delete rows that have the same 
> "Datetime" value as the prior row.

Well, if you do this, then you loose data.
is this really, what you want?
Throwing away data?
I would think it make sense, if all columns are equal, so that unique()
could be used - then you only throw away data, which already is registered
in your data frame.

But when you throw away different values because of the same date-time,
then there is the question: WHICH would you throw away?
All but the first? Or do you want to select a maximum or minimum?


You attempt looks strange to me...


Ciao,
   Oliver



More information about the R-help mailing list