Quantcast
Channel: Statalist
Viewing all articles
Browse latest Browse all 72771

Number of observations per participant

$
0
0
Hello, I am very new to Stata and need help with some simple commands.

I have got data from participants who have been measured repeatedly across different visits to see how variables change with ageing. I would like to calculate how many times each participant has been measured.

The data are in long form. Is there a way to create a new variable that assigns an observation number (e.g. first observation, second observation, third observation)? And calcuate the mean number of observations per participant?

Thanks

Viewing all articles
Browse latest Browse all 72771

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>