It might be a silly question, but I am struggling with it all day now. Hopefully someone with bright insight may be of any help.
I have this df which contains a column with ID names. Some ID names occur one time, other two, and some even 20 times. In other words some IDs are in 1 row, others in many rows.
What I would like to make is a new column which numbers the replicate IDs (from 1, 2, 3, etc.). I have tried ddply from plyr package, but that only gives me a new df with each unique ID followed by the number of replicates (that's not what I am looking for).
Any suggestions are welcome, thanks in advance!