How to calculate adjusted proportion for each group?

Adjusted mean for each group can be calculated using least squared method. How to calculate adjusted proportion for each group?
A SAS example data here,
data a;
input a b f g;
cards;
1 1 60 1
1 2 390 1
2 1 200 1
2 2 450 1
1 1 6 2
1 2 44 2
2 1 20 2
2 2 20 2
;
run;

proc freq data=a;
tables gab/riskdiff (common column=both CL=(WALD WILSON)) chisq fisher cmh cl alpha=0.05;;
weight f;
run;

It would help if you stated your ultimate analysis goals. And Cochran-Mantel-Haenszel methods are considered to be obsolete by most statisticians, yielding to logistic regression where it is easy to get adjusted probability estimates and to interpret them.