Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: st: Weighted proportion
From
"[email protected]" <[email protected]>
To
<[email protected]>
Subject
RE: st: Weighted proportion
Date
Thu, 4 Oct 2012 15:28:05 -0700 (PDT)
Have you tried
summarize rrace [weight=RWEIGHT]
?
Sent with Verizon Mobile Email
---Original Message---
From: [email protected]
Sent: 10/4/2012 5:13 pm
To: [email protected]
Subject: st: Weighted proportion
Dear statalist,
Any thoughts on a handy function or command to summarize the weighted
proportion? For instance, I have a variable that indicates to which
Race a respondent belongs. For example
RRACE = 1 if Hispanic
RRACE = 2 if White
RRACE = 3 if Black
RRACE = 4 if Other
Additionally I have a variable that weights the respondents (due to
oversampling of Hispanic's in my database), call this variable
RWEIGHT.
Now I want to summarize the weighted proportions of RRACE, i.e. how
much % is Hispanic, White, etc.
Obviously I can plot a histogram by the command [see below] which will
give me an overview of the proportions.
histogram rrace [weight = RWEIGHT], discrete width(1) percent
My question is: how can I get these proportions into the result window?
Thank you!
Daniel
*
* For searches and help try:
* http://www.stata.com/help.cgi?search
* http://www.stata.com/support/faqs/resources/statalist-faq/
* http://www.ats.ucla.edu/stat/stata/
*
* For searches and help try:
* http://www.stata.com/help.cgi?search
* http://www.stata.com/support/faqs/resources/statalist-faq/
* http://www.ats.ucla.edu/stat/stata/