Hi all!
I can't figure out a certain line of code. I'd like to merge two data sets. The master dataset looks as follows:
Array
And I'm trying to merge it with a dataset that looks like this:
Array
I know the specification "merge m:m country year using X.dta" works, however, it only merges the data if the year is available in the master dataset. The dataset I add has data starting from 2008 instead of 2012. How do I add empty year observations 2008, 2009, 2010, 2011 for each b_id in the master so that no data gets lost? Note that not all entries of b_id in the set start at 2012.
Kind regards,
Philippe
0 Response to Merging datasets code issue
Post a Comment