Hello, Can someone able to help to figure out how to add data point value in graph but not on X-axis. NOTE: I have to do this graph just for one subject. so all record in dataset LL is for one subject only. I Have attached my code and output here. As in graph, I am trying to add my data point (green triangle) inside the graph but, i don't want its value to display on X-axis(which is Cycle 6 Day 11). I want that value just to display in between cycle 6 day 1 and cycle 7 day1. data ll;
set lb_cm;
by subjid astdt ;
lag_adt=lag(astdt);
lag_visn=lag(avisitn);
lag_vis=lag(avisit);
if first.subjid then do; lag_adt= . ; end;
format lag_adt date9. ;
if astdt > lag_adt and avisitn eq . then do;
dys=astdt-lag_adt;
avisitn=sum(lag_visn,0.5);
avisit_1=substr(lag_vis,1,8)||" Day "||strip(put(dys,8.));
acyclec=substr(lag_vis,1,8);
acycle=(scan(lag_vis,2,' '))*1;
end;
if astdt_ ne '' then do; aval2=0.05; end;
if avisit='Screening' then do; aval2=.; end;
if avisit_1 eq '' then do; avisit_1=avisit; end;
run;
proc sgplot data=ll noautolegend cycleattrs;
styleattrs datacontrastcolors=(red green);
series x=avisit y=aval / DATALABEL=chg MARKEROUTLINEATTRS=acyclec curvelabelattrs=(size=10)
group=trtp lineattrs=(thickness=3);
scatter y=aval2 x=avisit / group=trtp markerattrs=(color=green symbol=triangle size=12);
yaxis display=all;
run; I have also tried y=avisit but in that case i am able to populated data point in graph and instead of four it only populate three (i.e. cycle 3 day 1 , cycle 6 day 1 , cycle 8 day 15). Any help will be appreciated. Thank you.
... View more