I am using a code below: and attached sample data. I am getting image as below. I want to show green color for Responders and red color for Non responders . %macro new (var1=,var2=, var3=,var4=); data v1v2&var3&var4/*(drop=sno)*/; set final1; if responder= 'Responder' then rsp=1; else if responder='Non-Responder' then rsp=2; if sno=1 then study= 'Harmony'; else if sno=2 then study='Encore'; where actarmcd= &var1 and paramcd= &var2; proc sort; by sno sub newn /*avisit responder*/; run; data myattrmap; set v1v2&var3&var4; retain id "myid"; value= responder; if responder eq "Responder" then linecolor= "green"; else linecolor= "red"; run; /*data myattrmap; /*input ID $ value $ markercolor $ markersymbol $;*/ /*set v1v2&var3&var4 myID ="myID"; value= sub; if responder= 'Responder' then linecolor= 'Green'; else if responder= 'Non-Responder' then linecolor= 'Red'; run;*/ proc format; value avis 0= 'HBase' 1= 'HWk20' 2= 'HWk38'; value stu 1= 'Harmony' 2='Encore'; run; proc sgpanel data= v1v2&var3&var4 noautolegend dattrmap= myattrmap; format /*newn avis.*/ sno stu.; title "Individual Biomarker panel Plot for Qualifying subjects with &var1 and &var2"; panelby sno/ spacing=5 novarname; scatter x=newv y=aval//*markers markerattrs= (symbol=circlefilled size=9)*/ group=sub /*curvelabel*/ /*attrid= myid */; series x=newv y=aval/ group= sub attrid=myid; rowaxis label="&var2"; colaxis label="Analysis Visit"; /*highlow x=newv high =hp75 low=hp25//*lineattrs=(thickness=2)*/ /*group=res;*/ run;
... View more