I'm having some issues referencing subset data tables made from a loop. The loop works fine and creates data tables named cond1, cond2, etc, but if I try to reference those newly created tables in later code, the script log says it can't find them. Oddly enough if I run my script peicewise, it works just fine.
for(i=1, i<=10, i++,
Original_table << select where(:Sorting Condition == i);
dti = Original_table << Subset(
Output table("cond"||char(i)),
Selected Rows( 1 ),
Selected columns only( 0 )
);
);
datatable("cond"||char(i)) << new column("random", numeric, continuous, formula(round(Random Uniform(1,150)),0));