Hi everyone,
I'm using Stata to deal with a hierarchical dataset, where I have level one data (individual) and level two data (household). My data looks like this:
So here each individual from the same household has same housesize. I want to get the mean and standard deviation of housesize, for instance with the data here it should be (57+140+120)/3 Which command should I use?
And since I have many variables like housesize, and I want mean, sd, max of all of them in one file, is there any command that do this directly?
Thank you so much!
I'm using Stata to deal with a hierarchical dataset, where I have level one data (individual) and level two data (household). My data looks like this:
Code:
ind_id household income housesize ----------------------------------------------- 1 1 12000 57 2 1 39000 57 3 2 27560 140 4 2 39000 140 5 2 25000 140 6 3 27435 120 7 3 22390 120 -----------------------------------------------
So here each individual from the same household has same housesize. I want to get the mean and standard deviation of housesize, for instance with the data here it should be (57+140+120)/3 Which command should I use?
And since I have many variables like housesize, and I want mean, sd, max of all of them in one file, is there any command that do this directly?
Thank you so much!
Comment