capture log close log using "SOCY699C-HW4-REGRESS-XML_TAB.txt", text replace /* xml_tab examples */ quietly regress sociability year i.sex i.race age educ estimates store m1 quietly regress sociability year i.sex i.race age educ i.marital estimates store m2 quietly regress sociability year i.sex i.race age educ i.marital attend1 reliten1 estimates store m3 xml_tab m1 m2 m3, replace estimates clear /* xml_tab examples */ label variable year "GSS Year" label variable sex "Sex" label variable race "Race" label variable age "Age" label variable educ "Years of education" label variable attend1 "Church attendance" label variable reliten1 "Strength of religious affiliation" quietly regress sociability year i.sex i.race age educ estimates store m1, title(Demographic) quietly regress sociability year i.sex i.race age educ i.marital estimates store m2, title(Marital Status) quietly regress sociability year i.sex i.race age educ i.marital attend1 reliten1 estimates store m3, title(Religion) #delimit ; xml_tab m1 m2 m3 using "example_out.xml", replace title("Sociability Models") stats(r2_a) constant(Constant) format((S3120) (N2304) rnames(v1 v2 v3 v4 v5 v6 v7 v8 v9 v10 v11 v12)); #delimit cr estimates clear log close