Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: Counting the number of records in long format data


From   "Christer Thrane" <[email protected]>
To   <[email protected]>
Subject   st: Counting the number of records in long format data
Date   Thu, 10 Nov 2005 00:40:33 +0100

Hi,

I have a panel data set in long format. The identifying record variable is
called lpnr. Sometimes an observation occupies one row (that is, the
variables for this variable is only measured once), somtimes it occupies two
rows (measured twice), sometimes three (measured three times) and so on.
However, I do not have a "time variable"--that is, a variable that counts
how many times (i.e. the number of rows) an observation appears? How can I
get this?

Best regards,

Christer

***************************************
Professor Christer Thrane
Department of Social Science
Lillehammer University College
2626 Lillehammer, Norway
+ 47 61 28 81 70 (fax)
+ 47 61 28 82 47 (phone, work)
+ 47 61 25 53 04 (phone, home)
+ 47 92 29 54 39 (mobile)


*
*   For searches and help try:
*   http://www.stata.com/support/faqs/res/findit.html
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/



© Copyright 1996–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index