Are you looking for something like this?
data plotdata;
infile cards dlm=",";
input
id group $ x y
;
if group = "A" then do;
ya = y;
end;
if group = "B" then do;
yb = y;
end;
cards;
1,A,10,2
1,A,30,10
1,B,110,400
1,B,140,150
2,B,110,750
2,A,20,11
2,B,150,600
2,A,70,7
3,A,100,16
3,A,75,8
3,B,120,800
3,B,130,1200
;
proc sort data=plotdata;
by x group id ;
run;
proc sgplot data=plotdata nocycleattrs;
step x=x y=ya /
justify=center group=id markers lineattrs=(pattern=solid thickness=0.8mm)
datalabel
;
step x=x y=yb /
justify=center group=id markers lineattrs=(pattern=solid thickness=0.8mm)
datalabel
y2axis
;
... View more