I have a question related to the interpretation and choosing the right model. Let me illucidate this with an example.
Code:
* Example generated by -dataex-. For more info, type help dataex clear input long entity int year float(borrowings wealth contro1 contro2) 11 2011 .5504084 .3566245 .001049701 . 11 2012 .5697871 .3026321 .04574671 .18446903 11 2013 .5391156 .4967295 .14580062 .03579957 11 2014 .51597077 .4602628 .10729927 .05016179 11 2015 .4759782 .4324788 .08659865 .0874485 11 2016 .4625662 .4278921 .071952224 .0022719898 11 2017 .39045715 .4538369 .11401688 .09341507 11 2018 .33070305 .4544985 .1488938 .08986207 11 2019 .2839154 .4448069 .12172364 .12575735 289 2011 .54094803 .3170305 -.035701364 . 289 2012 .5555683 .4265102 .20956197 .2240876 289 2013 .51333773 .43153745 .12207622 -.3072764 289 2014 .48577145 .3902475 .0349044 -.087109 363 2011 .4761355 .6830103 .10337277 . 363 2012 .4731195 .635296 .06661269 .1102981 363 2013 .53195494 .5600299 .04350695 -.3359406 363 2014 .4994195 .4138399 .09209046 -.3629895 363 2015 .51551414 .3602918 .04091703 .021681974 363 2016 .5284721 .4900997 .06195928 .07478184 363 2017 .5849603 .47596115 .04966863 -.14924355 363 2018 .4416465 .3467005 .017113568 2.728524 363 2019 .689352 .6998312 .010639434 -.661924 414 2016 .4542443 .03726708 -.06832298 . 414 2017 .006420134 .0480226 -.10297894 .3064353 414 2018 .005577936 .05113108 0 -.3771344 415 2018 . .25162724 -.06337353 . 415 2019 . .273057 .23241054 -.023724906 771 2013 .4651715 .29406333 -.0046174144 . 771 2014 .5203515 .24431875 -.04403596 .3764192 771 2015 .461695 .2143613 .02035333 .367132 771 2016 .5473848 .1589128 -.1711411 .2298338 771 2017 .5459776 .13162291 .02329034 .08634616 771 2018 .4951338 .11822204 -.014577627 -.024664767 771 2019 .4645513 .10804316 .09069066 .25544947 783 2011 .19831736 .4684654 .11470844 . 783 2012 .2092255 .4061761 .04089833 .2104566 783 2013 .19775394 .3961418 .006883122 .14734472 783 2014 .13007422 .366352 .08283698 .16174816 783 2015 .08677534 .42655 .03452697 -.021924905 783 2016 .033318035 .3804956 .07058284 .031698983 783 2017 .025697127 .3541734 .07881384 -.03924384 783 2018 .014560171 .3721915 .11289947 .03765883 783 2019 .0009790963 .3375435 .0960983 .16825883 1120 2011 .016338103 .2180963 .026797576 . 1120 2012 .032134537 .2383646 .062702514 .22125916 1120 2013 .08688986 .20360494 .0880451 .23629524 1120 2014 .05394961 .1738267 .20202254 .1875501 1120 2015 .03865692 .21615265 .1203531 .04958552 1120 2016 .06567325 .24021226 .21261434 -.03890164 1120 2017 .043705 .20884947 .0718712 .06808196 1120 2018 .03458266 .18803462 .08242624 .09054825 1120 2019 .031668555 .20853548 .04683747 .25766295 2248 2017 .1482503 .4667431 .025896344 . 2248 2018 .15626974 .48310015 .08627738 .09444503 2717 2011 .3987688 .52997494 .14493908 . 2717 2012 .5396248 .5388584 .15598004 .3650029 2717 2013 .521483 .4544449 .19313775 .005588582 2717 2014 .5139446 .4897545 .25459048 .18795657 2717 2015 .4747386 .4586011 .24208185 .0889574 2717 2016 .31001255 .45573065 .28510892 .17703804 2717 2017 .26234335 .4712567 .18955813 .04058781 2717 2018 .2209677 .7917002 .06728955 .5302293 2717 2019 .19191967 .699398 .074500315 .3378055 2842 2011 .24950735 .4182204 .3022586 . 2842 2012 .3842184 .47379285 .03693084 .3031987 2842 2013 .3622974 .5271885 .13663733 .2029563 2842 2014 .3780394 .5113045 .013650713 -.04777961 2842 2015 .3651952 .4876061 .08998302 -.017345913 2842 2016 .19154836 .08928572 -.27983585 -.617762 2842 2017 .012137886 .10746075 .3346093 .29977635 2842 2018 .11468551 .09463358 .001154068 .01475289 2842 2019 .1701168 .1248988 .032728113 .07911314 3335 2011 .3992996 .26422244 .01107776 . 3335 2012 .1974824 .19707473 .20451534 .7005484 3335 2013 .15542907 .1971979 .1561734 .07927933 3335 2014 .02286336 .2117583 .28621078 .08559263 3335 2015 .028543843 .22432104 .04865046 -.12535256 3335 2016 .03890818 .23201247 .1335648 .0577361 3335 2017 .05525101 .2071913 .05593624 .1520042 3335 2018 .10858244 .16878895 .04280683 .05487057 3335 2019 .2077677 .25074002 -.07555885 .033351693 3990 2011 .5109358 .4552348 .03000898 . 3990 2015 .4456229 .44618005 .10405827 . 3990 2016 .43831205 .4473882 .12087333 .037120655 3990 2017 .4056455 .4878761 .14671211 .05311526 3990 2018 .3955588 .4333314 .05018127 .0405465 3990 2019 .3502277 .42918175 .09828218 .2551483 3998 2011 .37776425 .29451075 .04358516 . 3998 2012 .3780212 .26692954 .07272071 .1514226 3998 2013 .39086115 .3095832 .10558873 .252045 3998 2014 .3920296 .30943435 .11797553 .2572871 3998 2015 .409129 .3290489 .11553278 .10464322 3998 2016 .4354037 .4199662 .19333223 .033969022 3998 2017 .4468606 .4847271 .13426812 .05140822 3998 2018 .4743695 .45495 .07626183 .20373327 3998 2019 .4099103 .36645475 .12567559 .09520283 4024 2018 .4125189 .394467 .026686385 . 4024 2019 .4504824 .4035377 .05246395 -.09097628 4030 2016 .17944816 .14157945 -.0003805899 . 4030 2017 .1738609 .08764988 .007434052 .3904321 4030 2018 .03812203 .064700745 -.071587935 .13233668 4030 2019 .07597651 .1156894 -.0385942 .18778832 4253 2011 .8300624 .8171949 .09131072 . 4253 2012 .794663 .8171949 .05564757 -.05502118 4253 2013 .762911 .8171949 .1105419 .1615684 4253 2014 .7336145 .8171949 .14773971 .071436204 4253 2015 .674849 .8171949 -.031225424 .0270546 4253 2016 .7137975 .8171949 .06298587 -.17491525 4253 2017 .7916883 .8171949 .09623498 -.4737846 4253 2018 .9276171 .8171949 .023376845 -.16493194 4253 2019 1.276667 .8171949 . -.4214988 4671 2016 .3638019 .2761481 -.013762163 . 4671 2017 .324754 .2852754 .1021458 .014223866 4671 2018 .24909975 .2877043 .13253058 .06868943 4671 2019 .1459749 .308847 .1335378 .1742925 4709 2012 .6662203 .6266319 .12137921 . 4709 2013 .6553847 .57591546 .11126392 .2181645 4709 2014 .5561621 .5362483 .22304483 .15842493 4709 2015 .54422885 .6040823 .11476488 -.020627577 4709 2016 .5054402 .6772127 .07680175 -.03030659 4709 2017 .4432106 .6758106 .1553518 .25886962 4709 2018 .4445682 .6200479 .07567866 -.012173307 4709 2019 .3930347 .5997105 .10580432 .14859356 5003 2011 .10918014 .067195535 -.1498538 . 5003 2012 .29134154 .1324779 -.008381018 .22241366 5003 2013 .3004852 .1650631 .08418134 -.1807024 5003 2014 .4097476 .1635043 -.005631727 .06136438 5003 2015 .4219355 .14122625 .06564905 .15401855 5003 2016 .5785052 .12588021 .03444713 .05206289 5003 2017 .6178731 .0944237 .02023365 -.033344425 5003 2018 .6006519 .0829053 .15445147 -.017999005 5003 2019 .4547431 .04478376 .000997468 .12755749 5284 2011 .018213866 .13102232 -.1010576 . 5284 2012 .009815243 .13163972 .010969977 .4374999 5284 2013 .01208981 .13356362 -.0011514105 .5177867 5284 2014 .002744237 .12513721 -.05433589 .2369791 5284 2015 . .1036617 -.002578649 .25052634 5284 2016 .002447381 .1977484 .1610377 .3619528 5284 2017 . .17095914 .04928952 .04697151 5284 2018 . .14962593 -.035743974 .031877268 5284 2019 .013277693 .3118361 -.04666161 -.07551485 5574 2011 .3480836 .34791905 .05428524 . 5574 2012 .3784089 .44763595 .08859126 .11765777 5574 2013 .39252335 .4043951 .02740591 .27299267 5574 2014 .3991644 .3555488 .05839193 .3259429 5574 2015 .4926058 .3930718 .04834897 .2213147 5574 2016 .33564585 .3325015 .05280495 .3620269 5574 2017 .3323925 .4069401 .02374232 .04540727 5574 2018 .3418147 .4148635 .05816296 .0852675 5574 2019 .3234833 .3989449 .07906775 .28092065 5747 2011 .5204021 .26908726 .033249445 . 5747 2012 .6293864 .3430454 .0043415455 .4871629 5747 2013 .6302891 .44336635 .069693 .18247823 5747 2014 .5998325 .5881558 .06856433 .1854033 5747 2015 .6428508 .6448769 .065628156 .17358422 5747 2016 .4589231 .25073498 .12238356 -.4735044 5747 2017 .436603 .28550306 .01621231 .07667357 5747 2018 .3116025 .1858569 .05198569 -.01696874 5747 2019 .26978314 .20869975 .07715876 .12243346 5757 2011 .6948834 .248067 .0539414 . 5757 2012 .7510648 .30751 .01876402 .8895615 5757 2013 .7640706 .53177357 .05485338 .6897347 5757 2014 .7093325 .7449082 .05202026 1.30066 5757 2015 .6998872 .7036348 .0908975 .21901853 5757 2016 .6356643 .684512 .06319894 .34603485 5757 2017 .6636555 .6877629 .05974928 -.10285632 5757 2018 .7051849 .6931466 .06781821 -.09978237 5757 2019 .6302482 .676382 .07526478 .1766577 5838 2017 .1730994 . -.007017544 . 5838 2018 .12154696 . -.025414364 1.244898 5838 2019 .29709467 . -.10403 -.52727276 6584 2014 . .1759436 .04661966 . 6584 2015 . .1658187 .09959914 -.00959966 6584 2016 .006420786 .1776915 .04278035 .04078111 6584 2017 .01701869 .1640328 .031530164 .01096856 6584 2018 .0165893 .1560764 .0531923 .03746163 6584 2019 .02165312 .13481045 .05877275 .22099447 6585 2016 .3712 .1824 . . 6585 2017 .2507317 .52 .3346093 .1858407 6585 2018 .0801282 .20352563 -.3121099 -.017910402 6585 2019 .0673516 .25114155 -.06392694 .10638297 6819 2011 .4224311 .3330956 .007585089 . 6819 2013 .4634391 .2912299 .10310937 . 6819 2014 .41481665 .28289443 .13677086 .08389007 6819 2015 .2757323 .6763028 .1288173 -.06943109 6819 2016 .22421573 .6315207 .206628 .3166479 6819 2017 .09270376 .688632 .184104 .1264415 6819 2018 .09099706 .6695513 .1580626 .17628655 6819 2019 .04310589 .6096967 .1581862 .07187309 6923 2013 .036216702 .3555073 .05436246 . 6923 2014 .05898787 .24557114 .06654391 .018220207 6923 2015 .001538993 .3057885 .0036747386 .04672977 6923 2016 .0007068081 .26764217 .06067091 .05069383 6923 2017 .08505154 .2234393 .0004295533 .08434212 6923 2018 .17396885 .20319186 -.07876948 .05308232 6923 2019 .13776949 .2279906 .1348017 .1045042 7068 2011 .2255373 .4336084 .005005895 . 7068 2012 .7127093 .08032516 -.04972092 1.466891 7068 2013 .3287078 .29266456 .3346093 -.1084349 7068 2014 .270276 .4778985 .09861256 .26408446 7068 2015 .23166804 .48211685 .12995677 -.2216417 7068 2016 .2082776 .5216338 .15304576 -.435073 7068 2017 .14068018 .36748925 .06736894 .7755268 7068 2018 .1372827 .579031 .095566 .21979836 7068 2019 .0975527 .5428747 .2242033 .1722421 7077 2011 .10389227 .3433261 .23245527 . 7077 2012 .017583195 .41385415 .20946424 -.10656785 7077 2013 .084119 .3831972 .013199246 -.02144102 7077 2014 .0899088 .3787669 .10190325 .0003639672 7077 2015 .1970248 .25454545 -.04181818 -.15655814 7077 2016 .3171595 .20603964 -.09366153 .53256845 7077 2017 .18523507 .5800278 .05884754 .0016043546 7077 2018 .24368845 .5597058 .01153124 -.064409144 7633 2013 .09921045 .27874687 .07949265 . 7633 2014 .15525705 .22930136 -.006302178 -.56791306 7633 2015 .1780412 .17021276 .074023396 .8443422 7633 2016 .22957626 .16778368 -.13163535 .22928523 7633 2017 .5346775 .14930987 .08845286 .25537586 7633 2018 .4951785 .25245413 .3131383 .073266946 7633 2019 .58521026 .20290634 -.11879278 -.1953571 8183 2011 . .1761822 -.15056667 . 8183 2012 . .2049998 .09631097 -.020935096 8183 2013 . .23560224 .05337045 .1179481 8183 2014 .03893272 .3249325 .09123235 -.030428946 8183 2015 .05951943 .3501657 .09422758 -.00829431 8183 2016 .1848452 .3448189 -.03573223 .031699587 8183 2017 .04137121 .4615638 .233529 .02830263 8183 2018 . .42928565 .1340962 .05503473 8183 2019 . .3720513 .06459869 .026408615 8312 2011 .1763868 .17379667 -.014755018 . 8312 2012 .21140324 .16629775 -.010693184 -.1752266 8312 2013 .25428674 .14817181 -.009161734 -.007726851 8312 2014 .2266215 .12879996 .01975407 -.3309977 8312 2015 .16589355 .11615896 .08863278 .10346692 8312 2016 .1230484 .1015561 .06620113 .1788599 8312 2017 .072696775 .086017 .10198997 .1414302 8312 2018 .02358453 .07827216 .06408186 .1542464 8312 2019 .04078949 .06777557 .05722944 .06567483 8523 2014 .024087144 .07042038 .17674133 . 8523 2015 .025539907 .0912676 .0037558686 .17436044 8523 2016 .0007068081 .06780822 -.004452055 -.419557 8523 2017 .012088436 .11468108 .10831875 .033965785 8523 2018 .017797846 .1888697 -.0114225 .11304883 8523 2019 .007172038 .15152065 .09060372 .8392238 8628 2017 .25019747 .3013428 -.192733 . 8628 2018 .1524776 .5681978 .01728817 .28799444 8628 2019 .11357084 .5739292 .06600082 .3025323 8893 2011 .3596167 .4037388 .17990266 . 8893 2012 .30688825 .3783531 .1176579 .3570038 8893 2013 .1736542 .3791348 .3258868 .3768252 8893 2014 .13743457 .2942589 .2237248 .2974286 8893 2015 .06304603 .25093853 .2433866 .22018386 8893 2016 .06197859 .3005768 .2174919 .1767114 8893 2017 .003652219 .31597325 .3267636 .1437075 8893 2018 .001664384 .4252501 .11356594 .07165918 8893 2019 .01824345 .392895 .12594202 -.03296312 9395 2011 .11527894 .05111475 -.17566568 . 9395 2012 .3116961 .2571288 .11172533 .53606766 9395 2013 .3572313 .19746792 . .52544016 9395 2014 .457702 .26060873 -.0010054614 .4435892 9395 2015 .36436895 .22284608 .11592472 -.3819741 9395 2016 .3786785 .2689725 .18334247 -.24169537 9395 2017 .3189563 .17134063 .08574134 -.19534147 9395 2018 .3941053 .10244358 -.026210876 -.53725356 9395 2019 .3029013 .04506692 .08439115 .6438882 9505 2016 .152146 .1488664 .23484957 . 9505 2017 .06109492 .12531224 .04964613 .28230104 9505 2018 .1964527 .10190892 -.18758455 .4303546 9505 2019 .163536 .07547297 -.0082811555 -.42026055 9793 2011 .21299487 .28313547 -.22727828 . 9793 2012 .2090286 .2395759 .14652154 1.0828497 9793 2013 .16243246 .19548473 -.008869908 -.07691464 9793 2014 .22626795 .16880143 .009572013 -.05456925 9793 2015 .2123294 .18939278 .04043563 .49040115 9793 2016 .15408486 .1600095 .05747928 .25603876 9793 2017 .1957748 .15506345 .10892046 .08424038 9793 2018 .2839797 .26066253 .027858667 .26903573 9793 2019 .3059011 .24024113 .08634496 -.13823473 10714 2011 .3242179 .4018814 .12119886 . 10714 2012 .3694196 .4118304 .05022321 -.08740239 10714 2013 .3186611 .4636268 .170796 .14660251 10714 2014 .22189525 .47969395 .0985874 .2188521 10714 2015 .1945914 .4244562 .058495 .007656967 10714 2016 .27926573 .3969305 -.02888956 .013297872 10714 2017 .1778991 .5967621 -.04951054 -.03787029 10714 2018 .11722489 .4629187 .00014952154 .8024161 10714 2019 .11691818 .4826052 -.026846703 .3995675 10735 2018 .56434965 .01147052 -.2837807 . 10735 2019 .4761131 .007799805 -.04029899 .1811359 10867 2018 .0938887 .005804029 -.11027654 . 10867 2019 .1117432 .002844372 -.3063795 . 10884 2015 .24478763 .2576126 .06100572 . 10884 2016 .1184179 .2610669 .13072436 .32687995 10884 2017 .0985217 .2684734 .070385665 .1563039 10884 2018 .12456716 .2851561 .033220906 .12491638 10884 2019 .10957008 .2936864 .09048726 .6531112 10903 2011 .4359254 .3555144 .08894213 . 10903 2012 .4086082 .4047706 .11770933 .22337973 10903 2013 .3936641 .3400377 .06047452 .26664123 10903 2014 .3441462 .3536265 .10754997 .2224479 end
Code:
**For Classical DID *Treatment group based on wealth bysort entity (year): egen avg_weal=mean( wealth) if inrange(year,2011,2015) // considering year till 2015 only bysort entity (year): egen max_avg_weal=max(avg_weal ) xtile tercile=max_avg_weal, nq(3) gen treat=1 if tercile==3 replace treat=0 if tercile==1 ** Time dummy gen time_dum=1 if year>2016 replace time_dum=0 if year<2017 **Setting the panel xtset entity year
Code:
*Running DiD . xtreg borrowings treat##time_dum contro1 contro2,fe vce(robust) note: 1.treat omitted because of collinearity. Fixed-effects (within) regression Number of obs = 147 Group variable: entity Number of groups = 21 R-squared: Obs per group: Within = 0.2162 min = 4 Between = 0.2142 avg = 7.0 Overall = 0.0121 max = 8 F(4,20) = 16.24 corr(u_i, Xb) = -0.3319 Prob > F = 0.0000 (Std. err. adjusted for 21 clusters in entity) -------------------------------------------------------------------------------- | Robust borrowings | Coefficient std. err. t P>|t| [95% conf. interval] ---------------+---------------------------------------------------------------- 1.treat | 0 (omitted) 1.time_dum | .0364757 .0405352 0.90 0.379 -.0480793 .1210307 | treat#time_dum | 1 1 | -.1493665 .0572354 -2.61 0.017 -.2687576 -.0299755 | contro1 | -.0110076 .0712315 -0.15 0.879 -.159594 .1375788 contro2 | -.0205239 .0143762 -1.43 0.169 -.0505121 .0094643 _cons | .3411113 .0143873 23.71 0.000 .3111001 .3711226 ---------------+---------------------------------------------------------------- sigma_u | .2453684 sigma_e | .0864247 rho | .88963071 (fraction of variance due to u_i) -------------------------------------------------------------------------------- . **Running Panel Regression . xtreg borrowings time_dum##c.wealth contro1 contro2,fe vce(robust) Fixed-effects (within) regression Number of obs = 239 Group variable: entity Number of groups = 42 R-squared: Obs per group: Within = 0.0905 min = 1 Between = 0.2895 avg = 5.7 Overall = 0.1388 max = 8 F(5,41) = 1.10 corr(u_i, Xb) = 0.2677 Prob > F = 0.3728 (Std. err. adjusted for 42 clusters in entity) ----------------------------------------------------------------------------------- | Robust borrowings | Coefficient std. err. t P>|t| [95% conf. interval] ------------------+---------------------------------------------------------------- 1.time_dum | -.0052656 .0575536 -0.09 0.928 -.1214975 .1109664 wealth | .1133002 .2026015 0.56 0.579 -.2958618 .5224622 | time_dum#c.wealth | 1 | -.1294753 .145374 -0.89 0.378 -.4230642 .1641135 | contro1 | -.1193711 .1043477 -1.14 0.259 -.3301056 .0913634 contro2 | .0095745 .030367 0.32 0.754 -.0517528 .0709019 _cons | .2812199 .0701817 4.01 0.000 .1394851 .4229547 ------------------+---------------------------------------------------------------- sigma_u | .18978849 sigma_e | .09432048 rho | .80193364 (fraction of variance due to u_i) ---------------------------------------------------------------------------------
As far as I understood the interpretation of DID involves, 14.93% change in dependent variable of those entities that has highest wealth relative to those entities with lower wealth in the post-period.
In panel regression, it means as the wealth increases in the post_period, then borrowings get reduced by 12.94%.
But what is that intuition of the difference in models? For instance treatment and control groups are created based on wealth and both implies that as wealth increases, borrowings decrease. But how EXACTLY IS MODEL 1 (DiD) different from Panel regression.
0 Response to Difference between a classical DID and panel regression wrt interaction term
Post a Comment