Hello everybody,
I need to reshape wide data to long. The issue is that I have two variables, but they aren't both in the wide format. I try to be clearer: for each individual (country) I have two records: one for the variable A and the second one for the variable B, so I do not have the variables on the same record (that is I do not have the variables in the wide format). Obviously, when I run:
reshape long newvar, i(country description) j(time)
I get both the variable in the same column vector "newvar". How can I split these data in order to generate two variables (two vectors, two columns)?
Thank you.
(STATA 12 user)
I need to reshape wide data to long. The issue is that I have two variables, but they aren't both in the wide format. I try to be clearer: for each individual (country) I have two records: one for the variable A and the second one for the variable B, so I do not have the variables on the same record (that is I do not have the variables in the wide format). Obviously, when I run:
reshape long newvar, i(country description) j(time)
I get both the variable in the same column vector "newvar". How can I split these data in order to generate two variables (two vectors, two columns)?
Thank you.
(STATA 12 user)
Comment