Statalist


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

Re: st: AW: Generating comparison tables


From   moleps islon <moleps2@gmail.com>
To   statalist@hsphsun2.harvard.edu
Subject   Re: st: AW: Generating comparison tables
Date   Thu, 23 Apr 2009 10:55:23 +0200

Thanks for the tip. However, I'm unable to get the two different
rowcatagories within the same two columns. I tried using the
appendmodels command suggested by Jann, but I get an error stating -
equation Domestic not found r(111);- This appendmodels program(from
the repec.org website) has worked beautifully in the past, but for
some reason not now.

webuse auto,clear
egen price2=cut (price),gr(5) label
egen weight2=cut (weight),gr(5) label
qui estpost tabulate weight2 foreign,chi2
eststo a
qui estpost tabulate price2 foreign,chi2
eststo b
eststo h:appendmodels a b
esttab h , main (b) aux (rowpct) eqlabels (,lhs(`e(rowvar)'))
stats(chi2 p) unstack

Also is there a way to put the  stats in a column by themselves
instead of in a row ?

Is there a way to have the category columns tabulated  ?

Regards,


On Wed, Apr 22, 2009 at 10:07 AM, Martin Weiss <martin.weiss1@gmx.de> wrote:
> <>
>
> Try -ssc d estout-, -help estpost, mark(ttest)-
>
>
> HTH
> Martin
>
>
> -----Ursprüngliche Nachricht-----
> Von: owner-statalist@hsphsun2.harvard.edu
> [mailto:owner-statalist@hsphsun2.harvard.edu] Im Auftrag von moleps islon
> Gesendet: Mittwoch, 22. April 2009 10:02
> An: statalist@hsphsun2.harvard.edu
> Betreff: st: Generating comparison tables
>
> Dear listers,
> I've been trying to find an easier automated way of creating
> comparison tables for two different groups across several variables.
> E.g compare the population in a treatment and placebo group (Columns)
> across multiple different categorical variables (Rows) and have each
> cell contain the frequency and percentage. Finally there should be a
> column including the p value for the difference between the groups
> (test specified by user). I'm sure there is an easy way to do this,
> but sofar I've been spending a lot of time copying and pasting into
> excel....
>
> Regards,
> *
> *   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/
>

*
*   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–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index