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

st: RE: How to display two distributions in one histogram?


From   "Scott Merryman" <[email protected]>
To   <[email protected]>
Subject   st: RE: How to display two distributions in one histogram?
Date   Wed, 19 May 2004 19:57:59 -0500

Jie,

Do you mean something like this:

sysuse auto

twoway (histogram weight if fore == 0, density blcolor(gs12) ///
 blwidth(medthick) bfcolor(gs15) legend(label(1 "Domestic"))) ///
(histogram weight if fore == 1, density blcolor(blue) blwidth(medthick) ///
 bfcolor(none)legend(label(2 "Foreign")) )

Scott

-----Original Message-----
From: [email protected]
[mailto:[email protected]] On Behalf Of Jie Chen
Sent: Wednesday, May 19, 2004 9:51 AM
To: [email protected]
Subject: st: How to display two distributions in one histogram?

A cubersome process is possible to tackle this, but I wonder any simple 
solution?

for example:
histogram price, by (foreign)

This will display two separate histograms, but I want them in one.

Thanks!


Jie Chen

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