Bookmark and Share

Notice: On March 31, it was announced that Statalist is moving from an email list to a forum. The old list will shut down on April 23, and its replacement, is already up and running.

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

st: Using outreg2 within a loop

From   Suryadipta Roy <>
Subject   st: Using outreg2 within a loop
Date   Wed, 13 Feb 2013 09:43:10 -0500

Dear Statalisters,

I am using the following form of code to get the regression results
within a table using -outreg2- :

forvalues i = 1(1)5 {
xttobit dep_var `controls' if period == `i', ll(0)
outreg2 using "C:\file.doc", nocons tstat dec(2) bracket keep(var1
var2) addstat(Adj. R-squared, e(r2_a)) word label `append'
local append "append"

When the file gets saved, two separate columns for "sigma_u" and
"sigma_e" are added for each of the five regressions. While I can
delete the columns manually, I was wondering if there is a suggestion
as to how to prevent them from appearing in the first place. Any
suggestion is greatly appreciated.

*   For searches and help try:

© Copyright 1996–2015 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   Site index