Monday, January 02, 2006
st: RE: egenmore xtile
This may help:
FAQ . . Calculating variables containing weighted group summary statistics . . . . . . . . . . . . . . . . . . . . . N. J. Cox and S. P. Jenkins 1/03 I want to calculate a variable containing weighted group summary statistics, but I do not want to collapse the data and egen does not support weights. How can I do this? http://www.stata.com/support/faqs/data/weighted.html
Sara Hussain > I would be grateful for advice on the xtile function. I have > created a categorical variable denoting quintile group > membership by region: > > egen quin=xtile(income), by region nq(5) weight(wght) > > I would like to know how I can create a variable that > includes a percentile value eg lowest quintle using weights. > I tried the folllowing but weights were not allowed: > > by region: egen lquint=pctile(income), p(20) > > Can xtile be modified for this? > > Also, please could anyone suggest a command incorporating > weights to create a mean variable for each group (in my case, region)?
* * For searches and help try: * http://www.stata.com/support/faqs/res/findit.html * http://www.stata.com/support/statalist/faq * http://www.ats.ucla.edu/stat/stata/
Links to this post: