Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
st: Looping through several hundred regressions and performing deseasonalising
From
Micha Schildmann <[email protected]>
To
"[email protected]" <[email protected]>
Subject
st: Looping through several hundred regressions and performing deseasonalising
Date
Thu, 6 Mar 2014 15:17:55 +0000 (GMT)
Hello everyone,
I am currently trying to deseasonalised a few hundred timelines. My command for a single time series looks like this.
sum ACCRUE, meanonly
local mACCRUE =r(mean)
reg ACCRUE January February March April May June July August September October November December, nocons
predict double ACCRUESA, residual
replace ACCRUESA=ACCRUESA+`mACCRUE'
So now I want to do that for all the time series in my data set. Is there a convinient way to loop the operation?
I was looking at foreach, but that did not work out.
Any help much appreciated.
Best
Micha
*
* For searches and help try:
* http://www.stata.com/help.cgi?search
* http://www.stata.com/support/faqs/resources/statalist-faq/
* http://www.ats.ucla.edu/stat/stata/