Mark: This is a survey data. every observation represents a certain
persons in the population. all the weights in the dataset addup to the
population. So the pweight is the weight I will use, isn't it?
Kit: Do I need to consider the weights while I am doing the demeaning?
I calculate the mean of a variable, should I use the sum of variables
the number of oberservations, or should I use the sum of the products
variable and weight, then divide the sum by the total weights? I hope
To answer the first question, NO, these smell like classic frequency
weights to me. As for the second, you can do the weighting in Jann's
center medage [fw=pop]
In my understanding that will give you a demeaned, appropriately
weighted median age variable.