I need to calculate unique ids within different intervals (3,4,5,6 months…) by for each month. I need to do that for different groups as well such as age, gender etc. This is how my data looks like: ID Yr_month Age Gender 11 2012-01 30 M 11 2012-02 30 M … 11 2012-12 30 M 12Read more