Dear All,
I am working on a bilateral data of the form;
exporter importer year trade
Germany France 2002 10000
I am trying to create a dummy following the pair of countries in the global and local sets below.
global EU "AUT BEL BGR CYP CZE DEU DNK ESP EST FIN FRA GBR GRC HRV HUN IRL ITA LTU LUX MLT NLD POL PRT ROU SVK SVN SWE CHE"
local ECOWAS "GHA BEN NGA BFA SEN CIV CPV GMB GIN GNB MLI NER TGO LBR SLE"
Hence I used the command;
foreach x of local EU & y of global ECOWAS {
gen DIV_EU=1 if exporter="x" & importer="y"
}
The above command seems not to work. Any suggestions
Related Posts with Using foreach for two set of groups
Within estimator singleton Code: sysuse auto split make encode make1, g(id) xtset id xtreg price displacement, fe Assume that …
metan Hazard Ratio log scaleHello, I am running cox regression and I want to make forest plot of my hazard ratios using metan. I…
Residual Variance Estimators: Calculating HC0 & HC1Hi everyone, This may seem like a very simple question but could someone please share the command f…
Creating new variables based on information from three other variablesI’m having some difficulty creating a new variable from three others. All variables are of binary ty…
test serial correlation for panel data for large T and small NHi I am using xtpcse for estimating my unbalanced panel (T=800 and N=9). What tests are available t…
Subscribe to:
Post Comments (Atom)
0 Response to Using foreach for two set of groups
Post a Comment