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

Re: st: Additional lines on histogram


From   [email protected]
To   <[email protected]>
Subject   Re: st: Additional lines on histogram
Date   Fri, 18 Nov 2005 16:06:36 +0100

Eric wrote:
I am generating a histogram but want to superimpose additional lines for
certain values on the x-axis. However, the additional line is basically
hidden behind one of the histogram bars, only appearing from the top of
the bar to the top of the graph. Is there a way to bring the additional
line to the top so that it is drawn on top of the histogram?
---------------------------------------------------------
You are right that an xline() becomes hidden behind the histogram. But
with -twoway histogram- you may add a line, e.g. using the -scatteri-
plottype:
   sysuse auto
   twoway (histogram mpg)(scatteri 0 20 0.1 20 , connect(l) msymbol(i))

Hope this helps
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: +45 8942 6090
Home:  +45 8693 7796
Email: [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