Dear Stata community,
I have currently an issue with the esttab command. I want to run a loop of regressions with different model specifications (a baseline and two specific ones, "export" and "climat") and different dependent variables (emphre empnbh diff_h emphre01 so 4 in total), giving me at the end 12 coefficients. Moreover, even if I have several independent variables, in my regression table I would like to display only the interaction term (dummy_treat here). However, with the esttab command I get a table with 12 columns and 1 row, whereas I would something a 4rows x 3 columns table:
Array
I tried to look at outreg, estout or matrices but, I am looking for a nice 4x3 regression table with beta coefficient and standard errors in bracket
This is the code that I have for now:
gen baseline=1
estimates clear
set more off
loc list_of_xs baseline climat export
foreach y in `list_of_xs ' {
local i = 1
foreach var of varlist emphre empnbh diff_h emphre01 {
eststo model`i'`y': xi: xtreg `var' dummy_treat dummy `y' if time==1 & (dum_ger==1 | dum_lux==1 | dum_che==1 | dum_bel==1) & emphre!=. & empnbh<70 & exclu_dd_reg!=1 & empnbh6>3 & exclu1!=1 & exclu2!=1 & nace!="EA" & nace!="ER" & nace!="EQ", fe robust cluster(newid)
local ++i
}
}
esttab, replace keep(dummy_treat) cells(b(star fmt(3)) se(par({ }) fmt(3))) starlevels(* 0.10 ** 0.05 *** 0.01) stardetach depvars ///
legend mlabels("Overtime Hours" "Hours Worked" "Gap" "Probability of Overtime" "Overtime Hours" "Hours Worked" "Gap" "Probability of Overtime" "Overtime Hours" "Hours Worked" "Gap" "Probability of Overtime") varlabel (off) varwidth(15)
Do you know I could actually re-configure my 1x12 regression table in a nice 4x3 table ?
Best,
Nicolas
* NB: Please note that I am using STATA 14
Related Posts with Problems with the Esttab command
Loop for excel file import and Kruskal –Wallis testDear User, I am trying to import several excel files and perform Kruskal –Wallis test test. Therefor…
Probit estimation with survey dataHello, I am dealing with a primary, cross-sectional data set that contains 360 observations and 26 v…
Instruments Specification xtabond2/xtdpdgmmHi, I am trying to estimate determinants of corporate cash holdings for ~700 firms across 16 years …
Categorisation of Explanatory Variables in Dynamic Panel EstimationsHi, I am trying to model determinants of corporate cash holdings for ~700 firms across 16 years. I …
Create local including next month's nameI am working on a project that involves re-randomizing our sample every month. As could be expected,…
Subscribe to:
Post Comments (Atom)
0 Response to Problems with the Esttab command
Post a Comment