Hi,
I am trying to add a heading for each categorical variable in my regression.
This is the code I am now using:
oprobit life_satisfaction population ${x}
est store est1
//LS for jews:
oprobit life_satisfaction ${x} i.migration i.migrate_year if population==1
est store est2
//LS for arabs:
oprobit life_satisfaction ${x} i.religion_arab
est store est3
esttab est1 est2 est3 using ls.doc, replace noomitted nobaselevels se pr2 label mlabels("Pooled" "Jews" "Arabs")
To generate the outcome:
--------------------------------------------------------------------
(1) (2) (3)
Pooled Jews Arabs
--------------------------------------------------------------------
married 0.251*** 0.243*** 0.245
(0.0558) (0.0645) (0.127)
divorced/separated -0.0670 -0.0194 -0.236
(0.0755) (0.0816) (0.254)
widow(er) 0.0453 0.0218 0.236
(0.0966) (0.106) (0.261)
1-<2 -0.0692 -0.0755 -0.0791
(0.0434) (0.0475) (0.120)
2+ -0.255** -0.127 -0.301
(0.0839) (0.115) (0.174)
I would like the outcome to be similar to the one below: (now added it by hand, but am searching for a code....)
--------------------------------------------------------------------
(1) (2) (3)
Pooled Jews Arabs
--------------------------------------------------------------------
Marital_status
married 0.251*** 0.243*** 0.245
(0.0558) (0.0645) (0.127)
divorced/separated -0.0670 -0.0194 -0.236
(0.0755) (0.0816) (0.254)
widow(er) 0.0453 0.0218 0.236
(0.0966) (0.106) (0.261)
Room_pp
1-<2 -0.0692 -0.0755 -0.0791
(0.0434) (0.0475) (0.120)
2+ -0.255** -0.127 -0.301
For the example above, I would like to add "marital_status" above the categorical variable and "room_pp" above another categorical variable. These are the names of the variables in my dataset
I have been looking up statalist but didn't find a simple solution for this.
Hope my answer is clear enough.
Thank you,
Shir.
Related Posts with Adding group name to categorical variables in esttab command
How to calculate the annualized three-month rolling sample standard deviation (based on the actual trading days)?Dear stata users, I' m following the Campbell et al.(2008) to calculate the failure probability of …
Summary table (F, df) for Mixed ModelsHello, I'm new to Stata and I'm trying to obtain a summary table for a mixed model as shown in the e…
Analyst Forecast DispersionHi All I am a beginner with Stata and am working with analyst data downloaded from IBES. I am using…
data calculation.Dear All, Suppose that I have the following data Code: * Example generated by -dataex-. To install:…
Estimate logit models with SUR and fixed effects included?Dear Stata enthusiasts, Is there any command that can be used to estimate two or more logit models …
Subscribe to:
Post Comments (Atom)
0 Response to Adding group name to categorical variables in esttab command
Post a Comment