Statalist


[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

Re: st: producing graph bar help


From   "Svend Juul" <[email protected]>
To   <[email protected]>
Subject   Re: st: producing graph bar help
Date   Mon, 7 Jan 2008 23:06:15 +0100

bw wrote:
 
i have data that look like this (portion of):
 
obs year ind_methd
1 2003 rapid
2 2005 standard
3 2004 emerg
4 2002 emerg
5 2002 emerg
6 2005 rapid
7 2006 rapid
8 2003 rapid
9 2006 standard
10 2005 rapid
11 2005 standard
12 2005 standard
13 2006 rapid
14 2002 rapid
 
i want to produce bar chart ala [G] p. 125, with year as x-axis and count 
of ind_methd as y-axis. however i only wanted rapid and standard to be 
shown on the chart. i am just wondering what i need to do to ind_methd 
variable to make: graph bar (count) ind_methd, over(year) bargap(-30) 
to work to show the graph that i wanted to show.
 
------------------------------------------------
 
Something like:
 
   gen x=1
   graph bar (count) x if ind_methd != "emerg" , over(ind_methd) over(year)
 
hth
Svend

________________________________________________________ 
 
Svend Juul
Institut for Folkesundhed, Afdeling for Epidemiologi
(Institute of Public Health, Department of Epidemiology)
Vennelyst Boulevard 6 
DK-8000 Aarhus C,  Denmark 
Phone, work:    +45 8942 6090 
Phone, mobile:  +45 2634 7796 
Fax:            +45 8613 1580 
E-mail:         [email protected] 
_________________________________________________________ 

*
*   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–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index