Dear Statalist members,
When using esttab from SSC (with Stata version 14.1), I fail to change the numerical format (use thousands separator) of the number of observations, N, provided I only use the esttab options scalars() and sfmt() and don't fall back on estout options such as stats(, fmt()). I would like to stick to the original esttab options in order to not disable further esttab options by using stats(), as explained in the estout help.
The following example should illustrate the problem:
set obs 1000
gen x=rnormal()
gen y=rnormal()
reg y x
eststo est1
esttab est1 using Esttab_test.txt, scalars(N) sfmt(%9.0fc)
*Here, thousands separator is not displayed in the created file.
esttab est1 using Estout_test.txt, stats(N, fmt(%9.0fc))
*Here, it is displayed.
Is there any way to change the format of N using only esttab options? I have already extensively studied the esttab/estout help and searched the internet, but couldn't find a solution. Thanks for any help.
When using esttab from SSC (with Stata version 14.1), I fail to change the numerical format (use thousands separator) of the number of observations, N, provided I only use the esttab options scalars() and sfmt() and don't fall back on estout options such as stats(, fmt()). I would like to stick to the original esttab options in order to not disable further esttab options by using stats(), as explained in the estout help.
The following example should illustrate the problem:
set obs 1000
gen x=rnormal()
gen y=rnormal()
reg y x
eststo est1
esttab est1 using Esttab_test.txt, scalars(N) sfmt(%9.0fc)
*Here, thousands separator is not displayed in the created file.
esttab est1 using Estout_test.txt, stats(N, fmt(%9.0fc))
*Here, it is displayed.
Is there any way to change the format of N using only esttab options? I have already extensively studied the esttab/estout help and searched the internet, but couldn't find a solution. Thanks for any help.
Comment