Hi, does anyone see an issue with my code.
//Table 5 - financial literacy and financial inclusion for women and men
estimates clear
reg fin_acc_f finlit_women lrealGDP_pc pop_15_64 prim_sch_enrol sec_sch_enrol privcredt_GDP banks_1000sqkm strength_leg_rights_idx ease_doing_busn_idx, r
outreg2 using table5.xls, replace
estimates store reg1
reg fin_acc_m finlit_men lrealGDP_pc pop_15_64 prim_sch_enrol sec_sch_enrol privcredt_GDP banks_1000sqkm strength_leg_rights_idx ease_doing_busn_idx, r
outreg2 using table5.xls, append
estimates store reg2
ttest [reg2]finlit_men = [reg1]finlit_women, by(fin_acc) unpaired unequal
//Problems: fin_acc isn't a variable in both reg1 & reg2 so when I run the ttest i get the error "varlist required - r(100)".
//Table 5 - financial literacy and financial inclusion for women and men
estimates clear
reg fin_acc_f finlit_women lrealGDP_pc pop_15_64 prim_sch_enrol sec_sch_enrol privcredt_GDP banks_1000sqkm strength_leg_rights_idx ease_doing_busn_idx, r
outreg2 using table5.xls, replace
estimates store reg1
reg fin_acc_m finlit_men lrealGDP_pc pop_15_64 prim_sch_enrol sec_sch_enrol privcredt_GDP banks_1000sqkm strength_leg_rights_idx ease_doing_busn_idx, r
outreg2 using table5.xls, append
estimates store reg2
ttest [reg2]finlit_men = [reg1]finlit_women, by(fin_acc) unpaired unequal
//Problems: fin_acc isn't a variable in both reg1 & reg2 so when I run the ttest i get the error "varlist required - r(100)".

Comment