Statalist


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: st: hist with addplot option


From   David Airey <[email protected]>
To   [email protected]
Subject   Re: st: hist with addplot option
Date   Tue, 25 Nov 2008 14:40:01 -0600

It will probably serve just as well to plot two kernel density functions. I know two of those can be plotted in the same graph.

Dave

On Nov 25, 2008, at 2:27 PM, Murali Kuchibhotla wrote:

Hello,
I am trying to plot 2 histograms on the same graph using the addplot
option as follows:

hist  math_grade if  MATH_cat==2 &  course=="econ_10", addplot(hist
math_grade if  MATH_cat==2 &  course=="psych_101") freq addl

However, when I run this I get the same graph as when I run:

hist  math_grade if  MATH_cat==2 &  course=="econ_10",freq addl

Can someone please tell me what I am doing wrong? Also, is there a way to
represent the bars of the 2 histograms in different colors? Thanks.

Murali Kuchibhotla


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