Format List Box text by value that naturally shows up when using the By clause in JSLHi all,
I am trying to make an individual oneway chart based on the value in a given list. I am able to do it in a for loop using where column == value in list and so on. The issue is that when I use a where clause I get this TextBox in the Listbox above the chart that I am unable to change the text of through JSL. I am able to change it when I right click and go into the properties but I want this to happen through code. Any help would be appreciated as this way doesn't show what the data is and can be misleading without me being able to change the text. The correct way happens when I use a generic By clause for the column but want that same look through code. Please look at the examples below.
dt = Open("$SAMPLE_DATA/Big Class.jmp");
types = {"F", "M"};
ow = Oneway(
Y( :height ), // Dependent variable
X( :age ), // Factor variable
Where(:sex == types[1])
);produces:

I would like this part to say :Sex == "F" so if the graph is in a report that it shows that it has been subsetted by "F" as right now it does not give such information.
Using this code:
dt = Open("$SAMPLE_DATA/Big Class.jmp");
ow = Oneway(
Y( :height ), // Dependent variable
X( :age ), // Factor variable
By(:sex)
);I get:

I know the for loop will give me "M" but how can I get the same details with sex=F onto the first one by using a where clause.
Thanks in advance and any help would be appreciated!
Automation and ScriptingBasic Data Analysis and ModelingData Exploration and VisualizationRe: Format List Box text by value that naturally shows up when using the By clause in JSLWhat needs to be done is to fully expand what is passed to JMP, so that when you pass the Oneway to JMP, there are not expression evaluations that need to be done.
Here is one way to do it:

dt = Open( "$SAMPLE_DATA/Big Class.jmp" );
types = {"F", "M"};
Eval(
Substitute(
Expr(
ow =
Oneway(
Y( :height ), // Dependent variable
X( :age ), // Factor variable
Where( :sex == _types_ )
)
),
Expr( _types_ ), types[1]
)
);