You can get your limits into a list, then use a variation of code snippet here to add reference lines. Note that there are two ways to do it via script that I know of. One is to set the column property (limit of 4 lines, stays with table and resulting plots), one is to the output, no limitation i know of, but does not get store to table for later use.
You can copy / paste to a script window and run it. Of course you'd need to loop through the parameters to fully automate to your needs.
Clear Log();
Names Default To Here( 1 );
dtData = open( "$SAMPLE_DATA\Variability Data\2 Factors Crossed.jmp");
// 1. add ref lines to the column property. It will be there for other plots as well.
// this first attempt doesn't work...
//column(dtData, "Measurement")<<set property("Axis", {add reference line(0.4), add reference line(1.2)});
// ... but this does. However, this column property appears to have a limit of four reference lines.
myAxis=expr(:Measurement<<set property("Axis", {Add Ref Line(aaa),Add Ref Line(bbb)}));
eval(substitute(nameexpr(myAxis), expr(aaa), 0.4, expr(bbb), 1.2));
//:mass << set property("Spec Limits", {65, 125});
// create the chart, store a referecne to it.
varChartObj = Variability Chart(
Y( :Measurement),
X( {:Operator, :part#} ),
Max Iter( 100 ),
Conv Limit( 0.00000001 ),
Number Integration Abscissas( 128 ),
Number Function Evals( 65536 ),
Analysis Type( Name( "Choose best analysis (EMS REML Bayesian)" ) ),
Show Range Bars( 0 ),
Connect Cell Means( 1 ),
Std Dev Chart( 0 ),
Points Jittered( 1 ),
Show Box Plot Whisker Bars( 0 )
);
// 2. The second way to do it is to add the reference lines after creating the plot. I don't know if there is a limit. I've used up to 10.
report(varChartObj)[axisbox(1)]<< add ref line (0.3, solid, red);
report(varChartObj)[axisbox(1)]<< add ref line (1.3, solid, red);
// without these, the ref lines would be out of view. You could also get the min / max of the window, and set the new min / max of the window based off min min and max max. I typically make the window's scale about 10% bigger than the min / max points of interest.
report(varChartObj)[axisbox(1)]<< min(0.2);
report(varChartObj)[axisbox(1)]<< max(1.4);