Can somebody explain why this:
dt = Open( "$SAMPLE_DATA/Fitness.jmp" );
col = { :Runtime, :RunPulse, :RstPulse };
y expr = Expr( Y() );
For( c = 1, c <= N Items( col ), c++,
Insert Into( y expr, col[c] );
);
Name Expr(y expr);
produces expected output
Y( :Runtime, :RunPulse, :RstPulse )
but this:
dt = Open( "$SAMPLE_DATA/Fitness.jmp" );
col = { :Runtime, :RunPulse, :RstPulse };
y expr = Expr( Y() );
For each({coll, index},col,
Insert Into( y expr, coll );
);
Name Expr(y expr);
produces this:
Y( ., ., . )
I would expect it to give the same result? How should I change FOR EACH loop to give the same result?