Hi,
I am trying to produce regresion tables using esttab. The first stat (% Change) appears with 15 decimals in the output table, and I want only 1 decimal. I can't change the format.
foreach y in $outcomes {
eststo: reg `y' x, robust
estadd local n= e(N)
estadd local method "OLS"
estadd local controls "No"
qui summ `y' if x==-1
estadd local Change=e(b)[1, 1]*100/r(mean)
eststo: reg `y' x $controls, robust
estadd local n= e(N)
estadd local method "OLS"
estadd local controls "Estado + dos"
qui summ `y' if x==-1
estadd local Change=e(b)[1, 1]*100/r(mean)
eststo: ivregress 2sls `y' (t=x), robust
estadd local n= e(N)
estadd local method "2SLS"
estadd local controls "No"
qui summ `y' if x==-1
estadd local Change=e(b)[1, 1]*100/r(mean)
eststo: ivregress 2sls `y' $controls (t=x), robust
estadd local n= e(N)
estadd local method "2SLS"
estadd local controls "Estado + dos"
qui summ `y' if x==-1
estadd local Change=e(b)[1, 1]*100/r(mean)
esttab using "$output\rft\Table3b`y'.rtf", se eqlabels(none) rename(x Elegible t Beneficiaria) keep(Elegible Beneficiaria) noobs stats(Change n method controls, label("% Change" "N" "Method" "Controls") fmt(%4.1gc %9.0gc %4s %15s)) nonotes addnotes("Errores estándar robustos entre paréntesis") star(* 0.10 ** 0.05 *** 0.01) b(%4.3f) rtf replace
eststo clear
}
I am trying to produce regresion tables using esttab. The first stat (% Change) appears with 15 decimals in the output table, and I want only 1 decimal. I can't change the format.
foreach y in $outcomes {
eststo: reg `y' x, robust
estadd local n= e(N)
estadd local method "OLS"
estadd local controls "No"
qui summ `y' if x==-1
estadd local Change=e(b)[1, 1]*100/r(mean)
eststo: reg `y' x $controls, robust
estadd local n= e(N)
estadd local method "OLS"
estadd local controls "Estado + dos"
qui summ `y' if x==-1
estadd local Change=e(b)[1, 1]*100/r(mean)
eststo: ivregress 2sls `y' (t=x), robust
estadd local n= e(N)
estadd local method "2SLS"
estadd local controls "No"
qui summ `y' if x==-1
estadd local Change=e(b)[1, 1]*100/r(mean)
eststo: ivregress 2sls `y' $controls (t=x), robust
estadd local n= e(N)
estadd local method "2SLS"
estadd local controls "Estado + dos"
qui summ `y' if x==-1
estadd local Change=e(b)[1, 1]*100/r(mean)
esttab using "$output\rft\Table3b`y'.rtf", se eqlabels(none) rename(x Elegible t Beneficiaria) keep(Elegible Beneficiaria) noobs stats(Change n method controls, label("% Change" "N" "Method" "Controls") fmt(%4.1gc %9.0gc %4s %15s)) nonotes addnotes("Errores estándar robustos entre paréntesis") star(* 0.10 ** 0.05 *** 0.01) b(%4.3f) rtf replace
eststo clear
}
Comment