cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Try the Materials Informatics Toolkit, which is designed to easily handle SMILES data. This and other helpful add-ins are available in the JMP® Marketplace
Choose Language Hide Translation Bar
BabyDoragon
Level I

Sharing a Local Data Filter between Graph Builders for synchronized data display

I 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 ) ) )
		);

	)
);
1 ACCEPTED SOLUTION

Accepted Solutions
jthi
Super User

Re: Sharing a Local Data Filter between Graph Builders for synchronized data display

You 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)

-Jarmo

View solution in original post

1 REPLY 1
jthi
Super User

Re: Sharing a Local Data Filter between Graph Builders for synchronized data display

You 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)

-Jarmo