Like this?
proc summary data=SASHELP.PRDSAL2 ;
where YEAR eq 1995;
class MONYR;
var ACTUAL PREDICT;
output out=SUMMARY sum=;
run;
data PLOT;
if _N_=1 then set SUMMARY(where=(MONYR eq .) rename=(ACTUAL=TOTAL) );
set SUMMARY(where=(MONYR ne .) );
retain TOTAL;
PCT+ACTUAL/TOTAL;
format PCT percent10.1;
run;
proc sgplot data=PLOT;
vbar monyr / response=ACTUAL ;
vline monyr / response=PCT y2axis;
run;
(modified from https://communities.sas.com/t5/SAS-GRAPH-and-ODS-Graphics/using-second-y2axis-with-proc-sgplot-vbar/td-p/73143)
... View more