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

st: egen mean function


From   Kit Baum <[email protected]>
To   [email protected]
Subject   st: egen mean function
Date   Thu, 18 Aug 2005 17:21:22 -0400

James wrote

Thanks. But when I use tssmooth, I am told there are
repeated time values in sample:

tssmooth ma st_7 = st, window(7 1)
repeated time values in sample

I have a number of cases for each time period. Any way
to get around this?


You need to tsset your data with both the individual and time indicator, e.g.

webuse grunfeld
tsset company year

Then tssmooth will operate separately on each panel within the dataset (as will egen filter).

Kit Baum, Boston College Economics
http://ideas.repec.org/e/pba1.html


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