This could be a possible implementation of the idea:
when data points get selected, the selcted ones get bigger and nicely visible, un-selected data points get smaller and faded.
By the way, there seems to be still some error in my code:
after selecting and deselecting data points, the additional column bounces back to "M"/"F" (like expected), but the formatting changed a bit.
setting on my computer (v 16.2.0, win) at the end:
{Legend Model(
3,
Properties(0,{Line Color( 3 ), Marker Size( 6 ), Transparency( 0.3 )},Item ID( "F", 1 )),
Properties(1,{Line Color( 21 ), Marker( "FilledCircle" ), Marker Size( 6 )},Item ID( "M", 1 )),
....
dt = Open( "$SAMPLE_DATA/Big Class.jmp" );
dt << New Column( "sexformula",
Character,
"Nominal",
Formula( If( N items(dt << get selected rows)==0 ,:sex ,If(Selected(),Concat(:sex," (selected)"), Concat(:sex," -" ))) ));
new window("test",
H list Box (
dt << Graph Builder(
Show Control Panel( 0 ),
Shol Legend(0),
Variables( X( :name ), Y( :weight ) ),
Elements( Bar( X, Y, Legend( 5 ) ) )
);
dt << Graph Builder(
Show Control Panel( 0 ),
Variables( X( :height ), Y( :weight ), Color( :sexformula ) ),
Elements( Points( X, Y, Legend( 3 ) ), Smoother( X, Y, Legend( 4 ) ) ),
SendToReport(
Dispatch(
{},
"400",
ScaleBox,
{Legend Model(
3,
Properties( 0, {Line Color( 3 ),Marker Size( 6 ),Transparency(1),Marker("Dot")}, Item ID( "F", 1 )),
Properties( 1, {Line Color( 21 ),Marker Size( 6 ),Transparency(1),Marker("Dot")}, Item ID( "M", 1 )),
Properties( -1, {Line Color( 3 ),Marker Size( 3 ),Transparency(0.3),Marker("Dot")}, Item ID( "F -", 1 )),
Properties( -1, {Line Color( 21 ),Marker Size( 3 ),Transparency(0.3),Marker("Dot")}, Item ID( "M -", 1 )),
Properties( -1, {Line Color( 3 ),Marker Size( 10 ),Transparency(1),Marker( "FilledCircle" )},Item ID( "F (selected)", 1)),
Properties( -1, {Line Color( 21 ),Marker Size( 10 ),Transparency(1),Marker( "FilledCircle" )},Item ID( "M (selected)", 1))
)}
)
)
)))