Statalist


[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

RE: st: exporting ereturn matrices with outreg2


From   Roy Wada <[email protected]>
To   <[email protected]>
Subject   RE: st: exporting ereturn matrices with outreg2
Date   Mon, 28 Jul 2008 12:00:03 -0700

>I would like to use -outreg2- to report some results from IV
>regressions which are saved into a matrix. Specifically, I am using
>-ivreg2- and the results I'm interested in are the F-statistics on
>excluded instruments (I have multiple endogenous regressors). These
>F-statistics are reported in the matrix e(first), in row 3 (columns
>correspond to the endougenos regressors).
>
>Davide Cantoni

The following code works for me. Also see this posting by Maarten 
to get at the p-values of F-statistics.
http://www.statacorp.com/statalist/archive/2008-01/msg00381.html

* set-up
cd d:
sysuse auto, clear
ivreg2 price (mpg head=rep trunk) weight length, first
mat first=e(first)
local F1=first[3,1]
local F2=first[3,2]

* visual
mat list e(first)
di "`F1' `F2'"

outreg2 using mystuff, addstat(F-stat mpg,`F1',F-stat headroom,`F2') see replace



_________________________________________________________________
Keep your kids safer online with Windows Live Family Safety.
http://www.windowslive.com/family_safety/overview.html?ocid=TXT_TAGLM_WL_family_safety_072008
*
*   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