Hi!
I have a cross-sectional time-series dataset and would like to add some firm-specific information from another dataset.
The variables I intend to use for merging is a company identifier (ds_code) and year. Unfortunately I have no idea why I receive 0 matched observations I checked for duplicates and the format should be fitting as well?
. merge m:1 ds_code year using "C:\Users\Desktop\Stata - Analysis\All_Financials.dta"
(note: variable ds_code was str6, now str7 to accommodate using data's values)
Result # of obs.
-----------------------------------------
not matched 1,992,565
from master 3,998 (_merge==1)
from using 1,988,567 (_merge==2)
matched 0 (_merge==3)
-----------------------------------------
Can anyone give me an advice from outside what might be the cause for this problem?
Thanks a lot!
Related Posts with Problems with merge command
merging datasets only if two variables matchHi all, I need to merge two datasets, but only if two variables from both dataset match. First data…
Pseudo R2 for logit and mlogit in multiple imputationHello, I am using multiple imputation and survey data with a logit model and would like to calculat…
Marking correlation coefficients on pwcorrHi, Using a dataset with many correlated variables, I'm interested in seeing if any of the pairwise …
Formatting dates correctly and calculating age from two datesHello, I'm sure someone has posted about this on the forum before but I can't find the exact answer…
RD Plot with Evenly Spaced binsHi all, I am trying to run RDplot while choosing my number of evenly spaced bins. If I want to have …
Subscribe to:
Post Comments (Atom)
0 Response to Problems with merge command
Post a Comment