Statalist


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

Re: st: estout: displaying single regression results in more columns


From   "Ben Jann" <[email protected]>
To   [email protected]
Subject   Re: st: estout: displaying single regression results in more columns
Date   Mon, 29 Dec 2008 09:49:37 +0100

There is no simple way to achieve that, but you could try something
like the following:

ssc install erepost, replace
clear
set seed 123
set obs 100
drawnorm y x1 x2 x3 x4
reg y x1 x2 x3 x4
matrix b = e(b)
matrix coln b = "eq1:x1" "eq1:x2" "eq2:x1" "eq2:x2" "eq2:_cons"
matrix list b
erepost b=b, rename
estout ., cells(b t) unstack eqlabels(none) collabels(, lhs(y)) drop(_cons)

Best,
ben


On Tue, Dec 23, 2008 at 5:36 PM, Emanuele Millemaci
<[email protected]> wrote:
> Dear Statalisters,
>
> I would like to display a regression output in two (or more than two)
> different columns by using the estout package.
> For instance, after preforming such a regression:
>
> reg y x1 x2 x3 x4
>
> I would like to get a file *.tex that looks
>
> y     b/t   b/t
> x1   b1   b3
> x2   b2   b4
>
> where b1-b4 are the parameters for x1-x4.
> It may seem meaningless to display results such a way but this is just
> an example.
> Thanks in advance,
> EM
> *
> *   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