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

st: A query on handling monthly data


From   Badri Narayanan Gopalakrishnan <[email protected]>
To   [email protected]
Subject   st: A query on handling monthly data
Date   Tue, 10 Jan 2006 17:14:53 +0530

Dear Statalist users and experts,
My dataset consists of monthly data of about 12000 households for 10
years, some of which are repeating and others are not. Data for all
months is not available, ie, for many months, there is no observation.
On an average, each year has data for 4 months. Though it's understood
that values are zero for non-reported months, I have't created extra
observations and filled-in zeros. Thus the monthly data is not in
regular intervals,i.e., this is with gaps.

Now, I need to do the following things with my dataset:
1. Create a timeid for each month, which is of stata-compatible form,
say, 1994m1,....  I have a variable for year and one for month, both
are integers.

2. Do tsset and then define a variable that takes, throughout, the
value of the first observation of each cross-section  of an existing
variable. This observation-number is not the same for most
cross-sections, as data for different crosssections may start in
different times!.

Though both of these problems seemed trivial to me before, I could not
do much and hence I really need your help to proceed further, atleast
for the problem 1.

Thanking you in anticipation.

Regards,
Badri Narayanan G.,

*
*   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