Dear all,
I'm encountering a formatting issue when using esttab to export regression results to .csv format in Stata/MP 18.0 for Windows.
Specifically, even though I'm using the star(* 0.10 ** 0.05 *** 0.01) option in combination with cells(b se t p), the significance stars do not appear in the exported .csv file.
Here's an example of my command:
esttab using results.csv, cells(b se t p) star(* 0.10 ** 0.05 *** 0.01) replace
I have tried the following steps:
My regression is a standard OLS model saved using eststo:
eststo: reg cognitive_function_score labor_participation_60plus xrage_capped95 male_dummy edu_category_6_new hukou_urban marital_married family_size_60plus has_social_activity_60plus has_social_insurance participate_pension_insurance adl_score_60plus num_chronic_diseases_60plus self_rated_health_60plus if xrage_capped95 >= 60, robust
Is this a known limitation of .csv output, or am I missing an option to force esttab to include significance stars in CSV files?
Thank you for your help!
Best regards,
HaoLong Luo
Here is result:
---------------------------------------------------
(1) (2) (3)
cognitive_~e cesd_total life_satis~n
b/se/t/p b/se/t/p b/se/t/p
---------------------------------------------------
labor_part~s -.0382372 .8640103 -.0663552
.0858771 .1381335 .0184968
-.4452552 6.254895 -3.587391
.6561464 4.17e-10 .0003358
xrage_cap~95 -.0608759 -.0513157 .0080893
.007384 .0119141 .0016355
-8.244334 -4.307138 4.946226
1.90e-16 .0000167 7.71e-07
male_dummy .3588725 -1.31744 .0147363
.083162 .1350253 .0178511
4.315345 -9.756987 .8255111
.0000161 2.26e-22 .4091039
edu_catego~w 1.472811 -.3885978 -.0395453
.0323219 .0521513 .00704
45.56699 -7.451348 -5.617197
0 1.02e-13 2.00e-08
hukou_urban .9467045 -1.21966 .0085871
.0967581 .1578647 .0207997
9.784244 -7.725986 .4128447
1.72e-22 1.24e-14 .6797305
marital_ma~d .6521948 -1.380666 .0591121
.0966979 .1696828 .0228056
6.744666 -8.136748 2.592001
1.63e-11 4.64e-16 .0095578
family_siz~s -.1471243 .121617 .013365
.0312912 .0520946 .0070285
-4.701785 2.33454 1.901538
2.62e-06 .0195907 .0572644
has_social~s .4619454 -.0896946 .0287325
.075337 .12476 .0164284
6.131717 -.7189365 1.748956
9.07e-10 .4721999 .0803337
has_social~e .8035194 -.5336196 .1179145
.1664072 .2888419 .0442734
4.828634 -1.847446 2.663325
1.40e-06 .0647175 .0077514
participat~e .419483 .0518434 .0791645
.1123816 .1832451 .0254235
3.732666 .2829181 3.113836
.0001907 .7772466 .0018527
adl_score_~s .1382105 -.3462736 .0160673
.0098475 .0193725 .0026156
14.03507 -17.87454 6.142898
2.89e-44 3.61e-70 8.46e-10
num_chron~us -.0415189 .4880617 -.020014
.0412254 .0779226 .0099822
-1.00712 6.263415 -2.004967
.3139053 3.95e-10 .0449973
self_rated~s -.0631688 -1.885264 .1851353
.0405395 .0668743 .0088861
-1.558202 -28.19115 20.83419
.1192219 3.4e-167 3.95e-94
_cons 3.261266 32.56528 1.507424
.6598937 1.105794 .1591561
4.942108 29.44967 9.471352
7.87e-07 1.5e-181 3.49e-21
---------------------------------------------------
N 8700 8464 8777
---------------------------------------------------
I'm encountering a formatting issue when using esttab to export regression results to .csv format in Stata/MP 18.0 for Windows.
Specifically, even though I'm using the star(* 0.10 ** 0.05 *** 0.01) option in combination with cells(b se t p), the significance stars do not appear in the exported .csv file.
Here's an example of my command:
esttab using results.csv, cells(b se t p) star(* 0.10 ** 0.05 *** 0.01) replace
I have tried the following steps:
- Tested multiple output formats: .doc, .docx, .rtf, .html, .txt, .csv.
- Verified that the syntax for star() is correct.
- Reinstalled the estout package (ssc install estout, replace).
My regression is a standard OLS model saved using eststo:
eststo: reg cognitive_function_score labor_participation_60plus xrage_capped95 male_dummy edu_category_6_new hukou_urban marital_married family_size_60plus has_social_activity_60plus has_social_insurance participate_pension_insurance adl_score_60plus num_chronic_diseases_60plus self_rated_health_60plus if xrage_capped95 >= 60, robust
Is this a known limitation of .csv output, or am I missing an option to force esttab to include significance stars in CSV files?
Thank you for your help!
Best regards,
HaoLong Luo
Here is result:
---------------------------------------------------
(1) (2) (3)
cognitive_~e cesd_total life_satis~n
b/se/t/p b/se/t/p b/se/t/p
---------------------------------------------------
labor_part~s -.0382372 .8640103 -.0663552
.0858771 .1381335 .0184968
-.4452552 6.254895 -3.587391
.6561464 4.17e-10 .0003358
xrage_cap~95 -.0608759 -.0513157 .0080893
.007384 .0119141 .0016355
-8.244334 -4.307138 4.946226
1.90e-16 .0000167 7.71e-07
male_dummy .3588725 -1.31744 .0147363
.083162 .1350253 .0178511
4.315345 -9.756987 .8255111
.0000161 2.26e-22 .4091039
edu_catego~w 1.472811 -.3885978 -.0395453
.0323219 .0521513 .00704
45.56699 -7.451348 -5.617197
0 1.02e-13 2.00e-08
hukou_urban .9467045 -1.21966 .0085871
.0967581 .1578647 .0207997
9.784244 -7.725986 .4128447
1.72e-22 1.24e-14 .6797305
marital_ma~d .6521948 -1.380666 .0591121
.0966979 .1696828 .0228056
6.744666 -8.136748 2.592001
1.63e-11 4.64e-16 .0095578
family_siz~s -.1471243 .121617 .013365
.0312912 .0520946 .0070285
-4.701785 2.33454 1.901538
2.62e-06 .0195907 .0572644
has_social~s .4619454 -.0896946 .0287325
.075337 .12476 .0164284
6.131717 -.7189365 1.748956
9.07e-10 .4721999 .0803337
has_social~e .8035194 -.5336196 .1179145
.1664072 .2888419 .0442734
4.828634 -1.847446 2.663325
1.40e-06 .0647175 .0077514
participat~e .419483 .0518434 .0791645
.1123816 .1832451 .0254235
3.732666 .2829181 3.113836
.0001907 .7772466 .0018527
adl_score_~s .1382105 -.3462736 .0160673
.0098475 .0193725 .0026156
14.03507 -17.87454 6.142898
2.89e-44 3.61e-70 8.46e-10
num_chron~us -.0415189 .4880617 -.020014
.0412254 .0779226 .0099822
-1.00712 6.263415 -2.004967
.3139053 3.95e-10 .0449973
self_rated~s -.0631688 -1.885264 .1851353
.0405395 .0668743 .0088861
-1.558202 -28.19115 20.83419
.1192219 3.4e-167 3.95e-94
_cons 3.261266 32.56528 1.507424
.6598937 1.105794 .1591561
4.942108 29.44967 9.471352
7.87e-07 1.5e-181 3.49e-21
---------------------------------------------------
N 8700 8464 8777
---------------------------------------------------
Comment