I'm running into an interesting problem with some JSL code used to invoke the Data Filter. With the following code the specified data is selected and the Data Filter window isn't shown as specified in JSL. However, if the code is run a 2nd time the Data Filter window is displayed and the specified data isn't selected. Once the Data Filter is manually closed and the JSL run again, the specified data is selected again. If the JSL code is run repeatedly, this alternating behavior continues each time. Any ideas why this might be occuring and how I can force the Data Filter to run each time without opening the DF window? Thanks.
Clear Log();
Names Default to Here ( 1 );
dt = Open( "$SAMPLE_DATA/Big Class.jmp" );
dt << Select Excluded;
dt << Clear Row States;
df = dt << Data Filter(
Show Window( 0 ),
Add Filter(
Columns( :age, :sex, :height ),
Where( :age == {13, 14, 15} ),
Where( :sex == "M" ),
Where( :height >= 50 & :height <= 65 )
)
);