Hello,
I have a large dataset that I have split into 10 chunks, I have written some code to loop through each Stata table applying the same processing code. However, when I highlight the script on the.do file, the code is printed on the Stata screen - but nothing happens - no errors, but the .dta files are not read into Stata as I would expect.
The beginning of the .do file is like this:
cd "X:xxxxxx\xxxxxx\xx"
local files: dir "." files "q10*.dta"
foreach files of local files {
Processing script e.g. merge and drop, creation of new variables
save `file', replace
}
I am at a loss as to what I am doing wrong.
Related Posts with Looping through Stata datasets applying the same processing code
Time Fixed effectsHello everyone, Just running a panel data regression, and the results for the Hausman test prove tha…
Merging datasets with one to many mappingHi All, My first dataset is an input-output matrix, that resembles the following: Code: * Exampl…
Education Calculation!Good Afternoon Everyone, I wonder if someone can help me to find a right command. I need to calcul…
How to calculate/obtain the standard errors of the residuals using FamaMacBeth with asreg fmb for Shanken Correction (1992)Hello everyone, I am currently trying to implement the Shanken (1992) Correction for my dataset aft…
Problem with delimitDear All, I have a master file from where I invoke other auxiliary files, the code being: Code: …
Subscribe to:
Post Comments (Atom)
0 Response to Looping through Stata datasets applying the same processing code
Post a Comment