Hi,
I want to merge two Stata datasets (both with >300 variables), of which ~200+ of the variables have the same name and the same meaning. I want the variables that have the same name and meaning to combine in the merged dataset. I have gone through and identified the different variables (the ones that don't have a corresponding variable in the other dataset) and added a prefix so that I will be able to identify them after the merge. In order for the duplicate variables to combine, do they need to be in the same format? In other words, do I have to go through and reformat all the variables I would like to combine? More specifically, would a variable that is formatted " byte %10.g" combine with a variable that is formatted "int %10g?" Is it just string and numeric that won't combine?
Also, is there a fast way to output variable formats using "describe" to a Word or Excel document?? I have tried "asdoc describe" and it doesn't work (only outputs variables and variable labels).
Thanks!
Clare
I want to merge two Stata datasets (both with >300 variables), of which ~200+ of the variables have the same name and the same meaning. I want the variables that have the same name and meaning to combine in the merged dataset. I have gone through and identified the different variables (the ones that don't have a corresponding variable in the other dataset) and added a prefix so that I will be able to identify them after the merge. In order for the duplicate variables to combine, do they need to be in the same format? In other words, do I have to go through and reformat all the variables I would like to combine? More specifically, would a variable that is formatted " byte %10.g" combine with a variable that is formatted "int %10g?" Is it just string and numeric that won't combine?
Also, is there a fast way to output variable formats using "describe" to a Word or Excel document?? I have tried "asdoc describe" and it doesn't work (only outputs variables and variable labels).
Thanks!
Clare
Comment