Write down the expression of the elasticity and then use lincom or margins with the expression option.
-
Login or Register
- Log in with
frontier lny c.lnx1##c.lnx1 c.lnx2##c.lnx2 c.lnx3##c.lnx3 c.lnx1#c.lnx2 c.lnx1#c.lnx3 /// c.lnx2#c.lnx3 if group1, distribution(tnormal) cm(z1-z4) /// predict te1 if group1, te predict xb1 if group1, xb
gen pred= . replace pred= xb1 if group1 replace pred= xb2 if group2 replace pred= xb3 if group3 frontier pred c.lnx1##c.lnx1 c.lnx2##c.lnx2 c.lnx3##c.lnx3 c.lnx1#c.lnx2 c.lnx1#c.lnx3 c.lnx2#c.lnx3, distribution(tnormal) cm(z5-z8) predict te_meta, te
webuse frontier1, clear frontier lnoutput lnlabor lncapital, vhet(size) predict te_vhet, te gen largefirms= size> 2000 lab def size 1 "Large firms" 0 "Small firms" lab values largefirms size *ALL FIRMS sum te_vhet *LARGE, SMALL AND ALL FIRMS table largefirms, stat(mean te_vhet)
. *ALL FIRMS
.
. sum te_vhet
Variable | Obs Mean Std. dev. Min Max
-------------+---------------------------------------------------------
te_vhet | 756 .2691245 .2071925 .0001571 .7643759
.
. *LARGE, SMALL AND ALL FIRMS
.
. table largefirms, stat(mean te_vhet)
-------------------------
| Mean
--------------+----------
largefirms |
Small firms | .2650408
Large firms | .272759
Total | .2691245
-------------------------
webuse frontier1, clear frontier lnoutput lnlabor lncapital, vhet(size) predict te_vhet, te gen largefirms= size> 2000 lab def size 1 "Large firms" 0 "Small firms" lab values largefirms size *ALL FIRMS sum te_vhet *LARGE, SMALL AND ALL FIRMS table largefirms, stat(mean te_vhet)
. *ALL FIRMS
.
. sum te_vhet
Variable | Obs Mean Std. dev. Min Max
-------------+---------------------------------------------------------
te_vhet | 756 .2691245 .2071925 .0001571 .7643759
.
. *LARGE, SMALL AND ALL FIRMS
.
. table largefirms, stat(mean te_vhet)
-------------------------
| Mean
--------------+----------
largefirms |
Small firms | .2650408
Large firms | .272759
Total | .2691245
-------------------------
Comment