Bookmark and Share

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: xline() on top of histogram


From   Alan Neustadtl <[email protected]>
To   [email protected]
Subject   Re: st: xline() on top of histogram
Date   Sat, 14 Apr 2012 13:48:29 -0400

One way is to use -graph twoway- and draw the histogram first and then
overlay a line.  The following does that with a vertical line at the
mean of the graphed variable:

sysuse auto, clear
graph twoway (hist mpg) (scatteri 0 21.3 .1 21.3, c(l) m(i))

Best,
Alan



On Sat, Apr 14, 2012 at 1:40 PM, Jorge Alé Chilet
<[email protected]> wrote:
> Hi, everybody,
> I want to draw a vertical line above a histogram. The command xline() draws a line that appears under the histogram bars. Do you have any sugestion?
> Thanks,
> Jorge
>
> *
> *   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/

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


© Copyright 1996–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index