I'm pretty new to pure SAS coding and trying to understand what the second last line is doing in below code
data dataset_2 (drop=column1 column2);
set dataset1;
by column3 column4 column5 column6;
retain column1 .;
if first.column6 then
column1=.;
column2=1;
if column6='Y' & abs(sum(column7,-column1))<10 then
do;
column2=0;
end;
column1 = column7;
if column8 = '?' then
do;
if column9<1000 or column3 in ('000000','111111','222222','33333','44444') then
do;
column8='n';
end;
else
do;
column8='Y';
end;
end;
if column2;
run;
Basically, the if column2;
portion?
Many thanks for the help! I understand the rest of the code