Notice: On March 31, it was **announced** that Statalist is moving from an email list to a **forum**. The old list will shut down on April 23, and its replacement, **statalist.org** is already up and running.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

From |
Nick Cox <njcoxstata@gmail.com> |

To |
"statalist@hsphsun2.harvard.edu" <statalist@hsphsun2.harvard.edu> |

Subject |
Re: st: Computing Quintiles with frequency weight |

Date |
Fri, 5 Aug 2011 07:36:01 +0100 |

Nick

Greetings,I am trying to observe comsumption patterns among the differentincome quintiles of a population. My sample contains 10 801observations, each with a corresponding frequency weight so as to berepresentative of the whole population (about 30 million people).I am using this command to compute my quintiles: xtile quintile= hhinctot[fw=weight], n(5) (hhinctot as the income variable)After doublechecking, I realized that some of my quintiles containedsubstantially less or more than 20% of the observations (whileeffectively taking in consideration the frequency weight - i.e. asif I duplicated myself the observations according to their frequency)this is the result I get: Quintile 1: 20,406% Quintile 2: 20,552% Quintile 3: 19,239% Quintile 4: 22,323% Quintile 5: 17,479%I can get more precise results by computing the quintile myself"manually", any idea why stata gets this far from 20%

* * For searches and help try: * http://www.stata.com/help.cgi?search * http://www.stata.com/support/statalist/faq * http://www.ats.ucla.edu/stat/stata/

**References**:**st: Computing Quintiles with frequency weight***From:*"Polloni Stefano" <stefano.polloni@umontreal.ca>

- Prev by Date:
**Re: st: Impulse Response analysis** - Next by Date:
**Re: st: RE: extract rownames corresponding to data as unique codes** - Previous by thread:
**st: Computing Quintiles with frequency weight** - Index(es):