ods listing close; ods html close;ods graphics off;
ods output FitStatistics=newname;
proc reg data=name;
model y=x1 x2;
by year industry;
run;
quit;
ods output AdditionalEstimates=pin;
data newname;
set newname;
by year industry;
if not first.industry then delete;
keep year industry nvalue2;rename nvalue2=Rsquare;
run;