Hi! I'm trying to create leads for the variable "annualearn" and I want to call them earn_t&i. For that, I am writing the following macro:
%macro forwardearn;
%do i=1 %to 7;
data analysis30;
set analysis30;
if eof&i=0 then
set analysis30 (firstobs=&i+1 keep=annualearn rename=(annualearn=earn_t&i)) end=eof&i;
else earn_t&i=.;
run;
%end;
%mend;
%forwardearn;
And I get the error: ERROR 22-7: Invalid option name +. , which I think it refers to the + in firstobs=&i+1 (only + in the macro).
Does anyone have an idea of what I am doing wrong??