我在b站找的代码:
ssc install corr2docx,replace
sysuse auto,clear
global V1 "price"
global V2 "mpg rep78 headroom trunk weight length"
winsor2 $V1 $V2 , cuts(1 99) replace
reg $V1 $V2
corr2docx $V1 $V2 if e(sample) using 相关系数矩阵.docx, star(* 0.1 ** 0.05 *** 0.01) replace fmt(%9.3f) title("表1:相关系数矩阵") note("注:*** p<0.01, ** p<0.05, * p<0.1")


雷达卡




京公网安备 11010802022788号







