Set Values for cells where number of cells is unknown.<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />Hi,
What is the easiest way to set values for cells, where the number of cells is unknown. For example, in the following script, it is possible to set all cells where :age==12 to :age==0, and the number of cells where :age==12 is unknown?
dt = Open( "$SAMPLE_DATA/Big Class.JMP" );
dt << Select Where( :age == 12 );
:age << Set Selected;
Column( "age" ) << Set Values( {0} );
Set Values for cells where number of cells is unknown.Perfect. Thanks!
Re: Set Values for cells where number of cells is unknown.This is one way to do it
dt = Open( "$SAMPLE_DATA/Big Class.JMP" );
dt << Select Where( :age == 12 );
:age[dt << Get Selected Rows] = 0;
//Or even simpler
dt = Open( "$SAMPLE_DATA/Big Class.JMP" );
:age[dt << get rows Where( :age == 12 )] = 0;