Statalist


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

st: Re: Generating comparison/contingency tables


From   "Martin Weiss" <[email protected]>
To   <[email protected]>
Subject   st: Re: Generating comparison/contingency tables
Date   Fri, 29 May 2009 23:38:00 +0200

<>

The dataset employed in the pdf is not a survey dataset as such- it is turned into one on page 29 via

-gen wt = int(uniform()*10)-


and, by implication,

-svyset wt-

which sort of tricks Stata into thinking it is dealing with survey data, although the weights are pure noise.

I think you could do the same to your data...


HTH
Martin
_______________________
----- Original Message ----- From: "Tomas M" <[email protected]>
To: <[email protected]>
Sent: Friday, May 29, 2009 9:43 PM
Subject: st: Generating comparison/contingency tables


Hello Statalisters,

Essentially, I want to create a comparison table, comparing a set of categorical predictor variables between outcome variables. I specifically want the Row %, with the 95% CI.

The exact table I want can be found at: http://www.ianwatson.com.au/stata/tabout_tutorial.pdf, page 20. This -tabout- command would be perfect, except that it requires survey data for that given example.


I want:

--------------.......Outcome 1.......Outcome 2.......Outcome 3.....--
---Predictor 1.....Row %, 95% CI...Row %, 95% CI...Row %, 95% CI...--
---Predictor 2.....Row %, 95% CI...Row %, 95% CI...Row %, 95% CI...--
---Predictor 3.....Row %, 95% CI...Row %, 95% CI...Row %, 95% CI...--
---Predictor 4.....Row %, 95% CI...Row %, 95% CI...Row %, 95% CI...--
---Predictor 5.....Row %, 95% CI...Row %, 95% CI...Row %, 95% CI...--
---Predictor 6.....Row %, 95% CI...Row %, 95% CI...Row %, 95% CI...--

Does anyone know how to do this with Stata?

I have tried estpost (but no -by- option with CI), fsum (but this switches around the rows and columns), tabstat (which allows me to switch rows and columns to my preferred orientation, but there no CI option).

I would appreciate any help at all!

Thank you

_________________________________________________________________
Internet explorer 8 lets you browse the web faster.
http://go.microsoft.com/?linkid=9655582
*
*   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