Is this what you are trying to do? (Script assumes the Fitness data is current).
P259 of the JMP Scripting Guide has a slightly more complicated example which illustrates this kind of thing. I jogged my own memory by doing the Oneway of Oxy and MaxPulse via a single Fit Model and saved all objects which resulted in a script where the 2 plots were joined with an H List Box. I changed the H List Box to a V List Box, inserted the Textbox (though it may be superfluous) and changed the window title to read "Box Plots".
If you want to change the titles of the individual box plots, make the changes manually on the output and save script for all objects (you will lose the textbox). The result will show you the syntax needed.
1. Run the script without your attempt to add a reference line. 2. In the output add the reference line(s) manually. 3. Save Script to Script Window 4. Note how the resulting script has implemented the reference lines 5. Modify your original script accordingly
If you read (very!) carefully the discussion of Oneway on page 196 of the Scripting Guide, you might be tempted to try something like (using the Fitness data):
where everything after the "50" is optional.
Oddly, even though the latter is, for me, a little easier to assimilate, it turns out (at least for me) that when you run that last code and then, from the output, save the script, the newly generated script *omits* the Yaxis modification!! This makes the former approach a little more appealing to me.