Hi, Thanks for the suggestion, I have updated my code as below: The below code error free outputs but have 3 warnings: WARNING: The ScatterPlot statement named 'lgnd1' will not be drawn because one or more of the required arguments were not supplied. WARNING: The SeriesPlot statement named 'lgnd2' will not be drawn because one or more of the required arguments were not supplied. WARNING: A blank graph is produced. For possible causes, see the graphics template language documentation. .When I try to give legend item , it gives the following error: ERROR 180-322: Statement is not valid or it is used out of proper order. how can i update this with increased line width in the legend ? *************************************************************************code below: ************************************** ods listing close; ods pdf file="&g_outfile..&g_fontsize" nobookmarkgen style=idsl dpi=600; proc sgplot data=&G_DDDATASETNAME dattrmap=myattr noautolegend tmplout='temp.txt'; scatter x=avisn y=aval_median / group=trt01a yerrorlower=aval_p5 yerrorupper=aval_p95 attrid=trt01a name="lgnd1" ; series x=avisn y=aval_median /group=trt01ax attrid=trt01ax name="lgnd2"; refline 1.35 / axis=y label="1.35 mcg/mL" labelpos=max labelloc=inside labelattrs=(size=7 color=grey) lineattrs=(pattern=solid color=grey thickness=0.01); refline 0.65 / axis=y label="0.65 mcg/mL" labelpos=max labelloc=inside labelattrs=(size=7 color=grey) lineattrs=(pattern=longdash color=grey thickness=0.01); refline 0.166 / axis=y label="0.166 mcg/mL" labelpos=max labelloc=inside labelattrs=(size=7 color=grey) lineattrs=(pattern=shortdash color=grey thickness=0.01); xaxis values=(5 to 42 by 1) valuesdisplay=("Week 5" "Week 6" "" "" "Week 9" "Week 10" "" "" "" "" "" "" "Week 17" "Week 18" "" "" "" "" "" "" "Week 25" "Week 26" "" "" "" "" "" "" "Week 33" "Week 34" "" "" "" "" "" "" "Week 41" "") label= 'Weeks from Randomization' Valuesrotate=Diagonal fitpolicy=rotatethin valueattrs=(size=7); yaxis label="Plasma CAB (mcg/mL)" TYPE=LOG LOGSTYLE=LOGEXPAND LOGBASE=10; *legenditem name="lgnd2" / lineattrs=(color=orange pattern=1 thickness=5) ; keylegend "lgnd2" /title="" ; run; options nofmterr; data dddata.xx _null_; infile 'temp.txt'; input; _infile_ = tranwrd(_infile_, 'statgraph sgplot', 'statgraph axistables'); _infile_ = tranwrd(_infile_, 'columnweights=preferred','columnweights=(0.2 0.1 0.4 0.15 0.15)'); call execute(_infile_); run; proc sgrender data=sashelp.class template=axistables; run; ods pdf close; ods listing;
... View more