Hello-
I have a repeated measures dataset (long form). I would like to summarize a few basic characteristics of the data and cannot figure out how to do so.
Example: Data are organized by Participant_ID and within Participant_ID are reporting_dates. I would like to get a unique count of reporting dates by participant.
I would like to create a new variable called Unique_dates so I can create a summary table like this:
I am learning to work with repeated measures data in Stata, so any assistance is appreciated.
I have a repeated measures dataset (long form). I would like to summarize a few basic characteristics of the data and cannot figure out how to do so.
Example: Data are organized by Participant_ID and within Participant_ID are reporting_dates. I would like to get a unique count of reporting dates by participant.
Participant_ID | reporting_date |
ID_1 | 1-Jan |
ID_1 | 1-Jan |
ID_1 | 1-Jan |
ID_1 | 2-Jan |
ID_1 | 2-Jan |
ID_1 | 3-Jan |
ID_1 | 3-Jan |
ID_1 | 3-Jan |
ID_2 | 5-Feb |
ID_2 | 5-Feb |
ID_2 | 5-Feb |
ID_2 | 6-Feb |
ID_2 | 6-Feb |
ID_2 | 7-Feb |
ID_2 | 7-Feb |
ID_2 | 7-Feb |
ID_2 | 8-Feb |
ID_2 | 9-Feb |
ID_2 | 9-Feb |
Participant_ID | Unique_dates |
ID_1 | 3 |
ID_2 | 5 |
Comment