Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.
From | "David Radwin" <dradwin@mprinc.com> |
To | <statalist@hsphsun2.harvard.edu> |
Subject | st: RE: RE: RE: Multiple histograms in one panel with pweights. |
Date | Wed, 16 Mar 2011 08:18:56 -0700 (PDT) |
It is not clear to me exactly what your data are and how you want to plot them, but it seems to me that you want to plot the distribution of one categorical variable by another categorical variable. If that is correct, I would look at Nick Cox's -catplot- (available from SSC), which creates bar graphs and dot plots for such data, and also his 2004 article "Speaking Stata: Graphing categorical and compositional data," http://www.stata-journal.com/sjpdf.html?articlenum=gr0004. -catplot- will accept aweights but not pweights, but aweights are perfectly adequate in this case and in the context of most graphs because most graphs only show point estimates. (For a recent example, http://www.stata.com/statalist/archive/2011-02/msg01383.html .) David -- David Radwin Research Associate MPR Associates, Inc. 2150 Shattuck Ave., Suite 800 Berkeley, CA 94704 Phone: 510-849-4942 Fax: 510-849-0794 www.mprinc.com > -----Original Message----- > From: owner-statalist@hsphsun2.harvard.edu [mailto:owner- > statalist@hsphsun2.harvard.edu] On Behalf Of Gupta, Sumedha > Sent: Wednesday, March 16, 2011 7:49 AM > To: statalist@hsphsun2.harvard.edu > Subject: st: RE: RE: Multiple histograms in one panel with pweights. > > Dear David, > > Thanks for your response. What do you think would be a better approach > than histograms in this case? > > Sumedha. > Dr. Sumedha Gupta > Assistant Professor > Department of Economics > Indiana University-Purdue University Indianapolis > 425 University Boulevard > Indianapolis, IN 46202-5140. > > ________________________________________ > From: owner-statalist@hsphsun2.harvard.edu [owner- > statalist@hsphsun2.harvard.edu] on behalf of David Radwin > [dradwin@mprinc.com] > Sent: Tuesday, March 15, 2011 6:05 PM > To: statalist@hsphsun2.harvard.edu > Subject: st: RE: Multiple histograms in one panel with pweights. > > I am not sure histograms are appropriate in this case. But if I > misunderstood, try Austin Nichols' -byhist-, available from SSC, which > allows pweights "at user's own risk" and will plot multiple histograms for > different categories in the same panel. > > Or see http://www.stata.com/statalist/archive/2007-10/msg00327.html . > > David > -- > David Radwin > Research Associate > MPR Associates, Inc. > 2150 Shattuck Ave., Suite 800 > Berkeley, CA 94704 > Phone: 510-849-4942 > Fax: 510-849-0794 > > www.mprinc.com > > > > -----Original Message----- > > From: owner-statalist@hsphsun2.harvard.edu [mailto:owner- > > statalist@hsphsun2.harvard.edu] On Behalf Of Gupta, Sumedha > > Sent: Tuesday, March 15, 2011 2:00 PM > > To: statalist@hsphsun2.harvard.edu > > Subject: st: Multiple histograms in one panel with pweights. > > > > Dear Statlisters, > > > > Using survey data with pweights I want to plot in one panel several > > histograms by categories. In particular I want to look at educational > > attainment (5 categories: less than high school, high school, some > > college, college and post grad) by age category of first child birth (6 > > categories). > > > > The histogram option does not allow pweights and the graph bar option > does > > not allow frequencies. Can anybody advise me on how I can get around > this? > > All help appreciated. > > > > Sumedha. * * 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/