Sharing a Local Data Filter between Graph Builders for synchronized data displayI would like to share the same Local Data Filter between two Graph Builders. For example, when selecting F, both Graph Builders should only display data related to F; and, when selecting M, both Graph Builders should only display data related to M.
How can I achieve this?
New Window( "Weight VS Height",
outlineBoxA = Outline Box( "Weight VS Height",
Graph Builder(
Size( 528, 456 ),
Show Control Panel( 0 ),
Variables( X( :weight ), Y( :height ) ),
Elements( Points( X, Y, Legend( 7 ) ) ),
Local Data Filter( Add Filter( columns( :sex ), Where( :sex == "M" ) ) )
);
Graph Builder(
Size( 534, 450 ),
Show Control Panel( 0 ),
Variables( X( :age ), Y( :weight ) ),
Elements( Points( X, Y, Legend( 7 ) ) )
);
)
);
Automation and ScriptingRe: Sharing a Local Data Filter between Graph Builders for synchronized data displayYou can use data filter context box
Names Default To Here(1);
dt = open("$SAMPLE_DATA/Big Class.jmp");
nw = New Window("Weight VS Height",
Data Filter Context Box(
outlineBoxA = Outline Box("Weight VS Height",
H List Box(
Data Filter Source Box(
dt << Data Filter(
Local,
Add Filter(columns(:sex), Where(:sex == "M"))
)
),
V List Box(
dt << Graph Builder(
Size(528, 456),
Show Control Panel(0),
Variables(X(:weight), Y(:height)),
Elements(Points(X, Y, Legend(7)))
),
dt << Graph Builder(
Size(534, 450),
Show Control Panel(0),
Variables(X(:age), Y(:weight)),
Elements(Points(X, Y, Legend(7)))
);
)
)
)
)
);
Write();
Construct Display Boxes for New Windows (jmp.com)