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

st: RE: graph: cross-plot of means


From   "Nick Winter" <[email protected]>
To   <[email protected]>
Subject   st: RE: graph: cross-plot of means
Date   Wed, 19 Jun 2002 09:24:30 -0400

> -----Original Message-----
> From: Kurmas Akdogan [mailto:[email protected]] 
> Sent: Tuesday, June 18, 2002 10:40 AM
> To: [email protected]
> Subject: st: graph: cross-plot of means
> 
> 
> Hi everybody,
> 
> I want to make a cross-plot of 'means' of two variables (say A and B)
> against a time variable (from 1993 to 2000).
> 
> Y axis: means of A from 1993 to 2000
> X axis: means of B from 1993 to 2000
> 
> I use stata 6.0.
> 
> Thanks

I'm not entirely sure what you want here - is it eight points, one for
each year, of the mean of A against the mean of B?  If so, then this
should do it:

	. collapse A B , by(year)
	. gr A B

You can trace out the time path of the points by sorting in date order
and the connecting the dots:

	. sort year
	. graph A B , c(l)

If that's not what you want, maybe you could clarify?

--Nick Winter

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