Stata novice here so please be gentle, but I have a dataset from a household survey. Basic demographic information (age, gender, education, etc) for each household member was collected. Currently in Stata the data is arranged horizontally such that it looks something like this:
hhid hh_m1 . age1 gender1 hh_m2 age2 . gender2 and so forth....
1 . father 45 1 mother 43 0
2 . father . 29 1 mother 26 0
3 . mother 34 0 son 7 1
4 . father 56 1 daughter 23 0
5 mother 42 0 daughter 20 0
and I want it arranged vertically to like this:
hhid hh_m age gender
1 father 45 1
1 mother 43 0
2 father 29 1
2 mother 26 0
3 mother 34 0
3 son 7 1
I've been playing around with the reshape command but just cant figure it out for the life of me. Any help would be seriously appreciated.
Guillaume
Related Posts with Reshape help for household data
Testing for serial correlation.Hey guys! I am running a fixed effects regression and wanted to test for serial correlation. I used …
HelpDear Statalists, I am doing a model with fixed-effects and need some help. Would maybe any of you b…
Panel Data - Basic linear regression using large accounting datasetHi all, I am a beginner to Stata and from watching videos can get a grasp of basic OLS, probit mode…
Regression with grouped variablesDear Stata Community In my paper, I want to investigate the impact of import competition on the inc…
Interrupted time series analysis with differing effect on specific subgroupsHi, I would like to perform an interrupted-time-series analysis to assess the impact of a policy on…
Subscribe to:
Post Comments (Atom)
0 Response to Reshape help for household data
Post a Comment