Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: Stacked bar chart of categorical data


From   "Fiona Bruinsma" <f.bruinsma@latrobe.edu.au>
To   <statalist@hsphsun2.harvard.edu>
Subject   st: Stacked bar chart of categorical data
Date   Thu, 27 May 2004 16:33:29 +1000

I have a number of categorical variables that I want to present on a stacked
bar chart (for each of the bars the height of the bar will be 100%).

My categorical variable (from 1-4) is the number of times an individual has
had a certain type of assessment by the outcome of interest (0=no, 1=yes).

I have included an example of the tabulated command I used to generate the
data I am trying to present graphically
tab2 DSM_mdep as_ht if self_ref==1, row mi

Ideally, I would then like to present on the same graph a number of
different types of assessment by the outcome (assessment1 by outcome,
assessment2 by outcome, assessment3 by outcome).

Catplot has been of some assistance but I haven't yet been able to get it to
stack the bars.

Regards,

Fiona

Ms Fiona Bruinsma
Research Fellow
Centre for the Study of Mothers' & Children's Health, La Trobe University
251 Faraday Street, Carlton
VIC  3053
Ph: (03) 8341 8583
Fax: (03) 8341 8555

*
*   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/



© Copyright 1996–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index