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

st: RE: expected values in tables


From   "Nick Winter" <[email protected]>
To   <[email protected]>
Subject   st: RE: expected values in tables
Date   Thu, 26 Sep 2002 10:33:38 -0400

> -----Original Message-----
> From: Richard Herrell [mailto:[email protected]] 
> Sent: Thursday, September 26, 2002 10:21 AM
> To: [email protected]
> Subject: st: expected values in tables
> 
> 
> 
> The list of tabulate options does not seem to offer displayed expected
> cells values (under the null).  Am I missing it or is it available in
> another command?

As far as I know there is nothing.  But you can roll your own:

	tabulate x y , matcell(actual)
	matrix exp =
((actual*J(`r(c)',1,1))*(J(1,`r(r)',1)*actual))/r(N)
	matrix list exp

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