is the goal to add only one reference line, or is the goal to add reference lines dynamically?
Sometimes I need to add reference lines based on data in a table. In this case, adding this script to customize the graph toes the trick.
//example
For Each Row(
If( :ref > 0,
V Line( Row(), Col Minimum( :weight ) - 10, Col Maximum( :weight ) + 10 )
)
)
In a little more context, this is what it looks like.
dt=open("$Sample_Data\Big Class.jmp");
dt<< New Column( "ref",
Set Values(
[0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0]
)
);
dt<<New Column( "Row",
Numeric,
"Continuous",
Format( "Best", 12 ),
Formula( Row() )
),
dt<<Graph Builder(
Size( 528, 446 ),
Show Control Panel( 0 ),
Variables( X( :Row ), Y( :weight ) ),
Elements( Points( X, Y, Legend( 3 ) ), Smoother( X, Y, Legend( 4 ) ) ),
SendToReport(
Dispatch(
{},
"Graph Builder",
FrameBox,
{Add Graphics Script(
2,
Description( "Script" ),
For Each Row(
If( :ref > 0,
V Line(
Row(),
Col Minimum( :weight ) - 10,
Col Maximum( :weight ) + 10
)
)
)
), Grid Line Order( 1 ), Reference Line Order( 3 )}
)
)
);
JMP Systems Engineer, Health and Life Sciences (Pharma)