Hi,
Here are two examples from the SAS Help Center:
data u1(keep=x);
seed=104;
do i=1 to 5;
call ranuni(seed, x);
output;
end;
call symputx('seed', seed);
run;
data u2(keep=x);
seed=&seed;
do i=1 to 5;
call ranuni(seed, x);
output;
end;
run;
Question 1: The call symputx in the u1, is used for the data step in u2?
If I modify the code from u1 to the one below:
data u1(keep=x);
do seed=1 to 5;
call ranuni(seed, x);
output;
end;
run;
Question 2: Why doesn't the modified code provide 5 different numbers? Each time the seed has a new value, which is like the seed in dataset u2, except it's not a macro variable.
Thanks!
... View more