I'm using sgplot and am trying to add a reference line for a certain month (march 2020) when I have the x-axis variable formated as yymmn6. However, using this sample code I get the following warning: WARNING: X='202003' is invalid. The plot will not be drawn. Which gives me the plot, without the reference line. How do I formulate the refline statement to get my line to show up? data test;
input monthno count;
datalines;
202001 78
202002 67
202003 99
202004 56
202005 63
202006 82
;
run;
data test;
set test;
time=input(put(monthno,6.),yymmn6.);
format time yymmn6.;
run;
proc sgplot data= test;
yaxis label="Amount";
xaxis label="Month";
series x=time y=count;
refline '202003' /axis=x;
run;
... View more