In a data.frame containing information on two parameters (date and station), I would like to label each unique combination of the two in a new column.
What I have:
df
date station
1 april GF3
2 december GF1
3 april GF2
4 april GF3
5 december GF1
What I want:
df2
date station Label
1 april GF3 1
2 december GF1 2
3 april GF2 3
4 april GF3 1
5 december GF1 2
Thanks!