为此,我们进一步采用xtregar命令来估计模型,首先考虑固定效应模型: •xtregarsqcpiunemgse5lndumt*,felbiiMLjinibaro-TolbsiMiumlharo-Tgjro-upsvwT*hHntPftwovernl口.1B3C0vwT*hHntPftwovernl口.1B3C0・0-07^00・&5F2Ok?s-periQiroup;mdm■BLViQmaixIO:L6OIOCO-Ifr<Li_1sqcoeT.std・Err.T.匸召...
use ShareHolderName_QFII, clear g Country = "" la var C 国家地区中文名 order C * cap pr drop A pr def A syntax [, a(string) n(string) *] replace C = "`a'" if regexm(S,"`n'") end * foreach i in 香港 加拿大 法国 新加坡 日本 挪威 科威特 台湾 澳门 荷兰 马来西亚 瑞士 韩国...
年波动率 use ccmsecm, clear keep GVKEY DATADATE TIC CUSIP TRT1M g year = substr(D,1,4) destring y, force replace replace TR=TR/100 bys year GVKEY: egen SD_Ret = sd(TR) drop D TR duplicates drop order year so y G drop if mi(S) label variable SD_Ret "Standard deviation of mo...
(IndustryC,"J") foreach v of var C006000000 Div RD A001218000 FA_D IndDirectorRa InsInvestorProp{ replace `v' = 0 if mi(`v') } bys y: egen m1 = median(C006000000) g x1 = C006000000 > m1 g lev = A002000000 / A001000000 bys y: egen m2 = median(lev) g x2 = lev < ...
) drop if mi(V) | length(V) <= 3 sca f_temp = "`f'" loc fname = substr(f_temp,1,11) loc Stkcd = substr(f_temp,1,6) g Stkcd = `Stkcd' g year = `y' order S y compress save "`fname'-TEXT.dta", replace } } } * forv y = 2006/2022{ cd C:\Download\社会责任...
清洗数据 A股 usefs_combas_annual_consolidate_new,clearmerge1:1Stkcdyearusingbdt_findistoscore,nogenxtsetStkcdyeargCE=A003000000-A003112101gRE=RetainedEarningsgTA=A001000000gLT=A002201000gST=A002101000foreachvofvarCERETALTST{replace`v' = 0 if mi(`v')|`v' <= 0}gEI=((CE-RE)-(L.CE-L.RE)...
use "C:\Download\data of RepRisk\reprisk_us.dta", clear keep REPRISK_ID ALL_ISINS drop if mi(A) duplicates drop split A, p(" ") drop ALL_ISINS gather A* drop var ren v ISIN drop if mi(I) duplicates drop compress save RepRisk_ISINS, replace * use RepRisk_ISINS, clear duplicate...