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: how to draw several kdensity curves in one graph


From   "Nick Cox" <[email protected]>
To   <[email protected]>
Subject   RE: st: how to draw several kdensity curves in one graph
Date   Wed, 3 Mar 2010 12:56:51 -0000

Only -plot()- works in Stata 8. -plot()- and -addplot()- both work in Stata 9 up, but -addplot()- is typically undocumented. 

Nick 
[email protected] 

Christopher Hajzler

I should have mentioned one more thing: I use an older version of
Stata (Stata 8), but when I was researching commands, some
instructions mentioned "addplot" instead of just plot, but this did
not work for me.  Possibly this is the command you would want to use
for more recent versions of Stata, but I am not sure.

On Wed, Mar 3, 2010 at 10:49 AM, Christopher Hajzler <[email protected]> wrote:
>
> Coincidentally, I was just wrestling with the same thing myself
> yesterday.  Here is the command I used:
>
> kdensity var if (year==1999), plot(kdensity var if
> (year==1989)||kdensity var if (year==1979)) legend(ring(0) pos(2)
> label(1 "1999") label(2 "1989") label(3 "1979") )

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