Good morning everyone.
I need to merge two datasets but the do file doesn't work. The structure is this:
use dataset2
sort countryname year
save dataset2, replace
use maindataset
sort countryname year
merge countryname year using dataset2 --------------------> at this point appears this message: (you are using old merge syntax; see [D] merge for new syntax); variable _merge already defined r(110); and the Do-File end
drop if _merge==2
save maindataset, replace
Someone could explain me why?
Related Posts with Merge two datasets
Reformatting Matrix for Event StudyDear Statlists, I am currently working on an event study with a focus on the acquirers stock price …
Regression in data panel. Collinearity with FEHello, I am struggling with my data panel analysis. I am conducting a research with information of …
Between group difference of 2 groups with covariate-adjusted meansHi, I am new to Stata and I need to know how can I go about comparing the adjusted means between 2 …
Bayesian Nominal Response ModelPlease the entire house, I need someone to guide me on how I can fit nominal response model using ba…
extracting components from filename including special charactersHi, i received a bunch (several hundred) of xls. files that should be read into Stata. Unfortunately…
Subscribe to:
Post Comments (Atom)
0 Response to Merge two datasets
Post a Comment