Dear stata members,
I am trying to loop over multiple files (rounds) of data. In the first two rounds of data, there are only 2 wage variables. However, in the later rounds there are 5 wage variables. Even when I generate the 3 wage variables that are missing in rounds 1 and 2 in those rounds using a unique round_ID, I get the error that those variables are already defined. What command do I add into the loop to tell stata to either skip over these variables in the first two rounds or generate the variables such that it doesn't give me an error later?
Thanks in advance.
Best,
Janaki
Related Posts with looping over multiple files - there are new variables in some files
If else inside for each loopI am trying to run the following code and it does not seem to be working. I want to change the refer…
how to keep month end data from daily data (with various month-ending dates)Dear All, I have a daily data set with different month-ending date (sometime on 27 or 28 or 29 or 30…
logit regression with categorical variables: obtain p-value of the difference to the basecategoryHi, I am trying to estimate a logit model using survey data. I have a categorical variable (age gro…
Forming new variable using several existing variablesHi, I am trying to create a variable "IN" that takes value from existing variables "IN_1 IN_2 IN_3 I…
Results are generating omitted dummy variables for fixed effect panel regressionsI have the following fixed effect regression where i wanted to control for ID and year fixed effects…
Subscribe to:
Post Comments (Atom)
0 Response to looping over multiple files - there are new variables in some files
Post a Comment