Dear all,
assuming I have this code and I wish to add a linear such as a regression line to show the trend of the curve
how do I do that
data have;
infile datalines;
input year 4. pats_stage1_3 pats_total 3. ;
datalines;
1999 150 300
2000 112 369
2001 236 426
2002 121 400
2003 330 520
2004 280 500
;
run;
proc sgplot data=have noborder;
series x=year y=pats_stage1_3 / lineattrs=(color=blue);
series x=year y=pats_total / lineattrs=(color=green) ;
xaxis type=discrete display=(nolabel) discreteorder=data offsetmin=0.1 offsetmax=0.1 ;
yaxis display =(nolabel) values=(0 to 600 by 100) valueattrs=(family=arial size=5pt ) minor grid ;
keylegend / location=outside position=bottom title="" valueattrs=(size=7pt family=arial) outerpad=(top=0.2cm) noborder;
run;