first question, sorry if I missed it while searching for an answer.
I have a dataframe with a column called 'id', with each id appearing several times. I'm trying to add a column to this dataframe that basically represents the sequence of occurrences of each unique 'id'. For example:
id: 1, 1, 1, 2, 2, 3
count: 1, 2, 3, 1, 2, 1
Sorry for horrible formatting, I'm so exhausted at this point, any help is appreciated!!!