Dear Statalist users,
Good day to you firstly. I have 2 STATA datasets, where I'd like to transfer the variable GDP per capita from the 2nd dataset to the first dataset. The problem is that the number of years are not the same, as well as the fact that the first dataset is missing several years. If any of you have any idea as to how I can still add the variable from the second to the first dataset, I would be very grateful. Thank you very much. The first dataset looks as follows:
country year median
Argentina 1986 xxx.xx
Argentina 1987 xxx.xx
Argentina 1989 xxx.xx
Argentina 1990 xxx.xx where xxx.xx is just a number (e.g. 530.44)
Brazil 1990 xxx.xx
Brazil 1991 xxx.xx
Brazil 1992 xxx.xx
Brazil 1995 xxx.xx
And the second dataset:
country year GDP per capita
Argentina 1990 xxx.xx
Argentina 1991 xxx.xx
Argentina 1992 xxx.xx
Argentina 1993 xxx.xx
Brazil 1990 xxx.xx
Brazil 1991 xxx.xx
Brazil 1992 xxx.xx
Brazil 1993 xxx.xx
Once again thank you for your time.
Kind regards,
Ryan
Related Posts with Adding variable from one STATA data set to another
Egen with an if statementHi, I have a long dataset with multiple observations per patient id. I’m trying to generate a medic…
Remove combination of quotes and asterisk in variable labelHi all, I have a extrange combination of quotes and asterisk in variable label in my data base... L…
Problem in labels with splitvallabels Hi all, I am having problems in labelling graph with splitvallabels and catplot, I suspect that the…
estimate gravity model to calculate potential trade by uisng OLS, REM, FEM, TOBIT and PPLMHi everyone, I'm new here. I am working on my Ms.thesis. the topic related to DETERMINANTS AND POTEN…
Problem running synth_runner commandHi there! I'm having problems running synth_runner command. There are various treated units giving a…
Subscribe to:
Post Comments (Atom)
0 Response to Adding variable from one STATA data set to another
Post a Comment