I wish the following code could help u.
data test01;
input x @@;
y = ceil(abs(10*rannor(0)));
cards;
2 5 9 10 11 13 24 31 10
;run;
data test02(keep = x y t);
retain x1-x4;
set test01;
if _n_ <= 4 then do;
select (mod(_n_,4));
when (1) x1 = x;
when (2) x2 = x;
when (3) x3 = x;
otherwise x4 = x;
end;
end;else do;
select (mod(_n_,4));
when (1) do;t = x; x = x1*(1+y); x1 = t; end;
when (2) do;t = x; x = x2*(1+y); x2 = t; end;
when (3) do;t = x; x = x3*(1+y); x3 = t; end;
otherwise do;t = x; x = x4*(1+y); x4 = t; end;
end;
end;
run;



雷达卡





京公网安备 11010802022788号







