Here are 2 ways to do what you want. One uses just straight JSL to hide and exclude the rows. The second example uses a Data Filter(not a Local Data Filter) which allows one to interactively do the hide and exclude
names default to here(1);
dt=open("$SAMPLE_DATA/big class.jmp");
dt << set name("example 1");
dt << new column("category", set each value(random integer(0,1)));
dt << select where(:category==0);
dt<<HIDE and="" exclude=""></HIDE>