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: Three-way (or more) histograms in Stata
From
Austin Nichols <[email protected]>
To
[email protected]
Subject
Re: st: Three-way (or more) histograms in Stata
Date
Tue, 9 Oct 2012 10:45:06 -0400
Tim Evans <[email protected]>:
See also -byhist- on SSC.
On Tue, Oct 9, 2012 at 9:45 AM, Tim Evans <[email protected]> wrote:
> Hi all,
>
> I am trying to generate histograms (in Stata 11.2) with age distributions for three categories overlaid in the same graph for different periods. Essentially I want to visually check whether the age distribution of the cohort in an age group changes between periods, and whether the distribution of sub groups of the population also change.
>
> I started off with -histogram- because this nicely collapses my patient level data, without me having to do this manually. However, while I found twoway to be an option to increase the number of series plotted on the graph, I guess what I'm really after are line plots which would allow transparency between the series.
>
> I'm using the followinhg code to present single categories of interest (but for each level in my age group) and use the -by()- to present all periods on one combined graph (separate for each age group)
> My questions are:
>
> Can I ask -histogram- to plot lines rather than bars?
> Can -histogram- (with lines if possible) plot more than 2 series of data
>
> If -histogram- will not do this, what is a better method of doing this?
*
* 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/