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

st: RE: Using statsby and corr to ouput a table of correlations


From   "Nick Cox" <[email protected]>
To   <[email protected]>
Subject   st: RE: Using statsby and corr to ouput a table of correlations
Date   Thu, 31 Jul 2003 17:44:02 +0100

Joseph McCrary

> I am using the following command in Stata 7 SE:
>
>      statsby "corr  engscale mark" r(corr_12)  r(N), by(sch_e)
>
> to generate a table of correlations by school. When I list
> the results, I get:
>
>          sch_e     _stat1     _stat2
>   1.        40          .        845

>  24.       488          .         27
>
> Why is _stat1 missing? What should I place in the statsby command to
> produce the correlation matrix?

-correlate- leaves the correlation behind in r(rho). The covariance
is left behind in r(cov_12).

Nick
[email protected]

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