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]
st: collecting tabulate results
From
"Broudy, David, DOH" <[email protected]>
To
"[email protected]" <[email protected]>
Subject
st: collecting tabulate results
Date
Tue, 8 Feb 2011 17:46:17 +0000
In a survey, we asked which hospital services respondents had used:
Dental
Diabetes
Mental Health...there are a total of 9 services
For each service, we asked a separate question with answers 1=yes, 0=no.
We would like to make a bar graph showing the number and percentage of "yes" responses for each service (variables are named N8A-N8I)
Of course, I can run tabulate nine times, record the number of "yes" answers to each question, enter this into Excel, and use this to make the bar graph.
Is there a way to collect the positive responses to a series of tabulates and use those with graph?
When I do this manually, I make a file the looks like this:
Prgm, freq, pct, n
Dent,39, 30.7,127
DB,71,55.0,129
MH,106, 82.8,128...
Then: graph bar freq, over(prgm, sort(1)) etc
We have quite a number of questions formatted like this, so an alternative to doing it manually would be helpful.
Thank you,
David
NM Dept Health
*
* 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/