cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
JMP is taking Discovery online, April 16 and 18. Register today and join us for interactive sessions featuring popular presentation topics, networking, and discussions with the experts.
Choose Language Hide Translation Bar
samshaw
Level I

how to remove "Where" from graph builder report window

Hello,

I have a script, that creates multiple graphs by parameter and put them in a report window.

the output creates a text above the outline box "Where parameter=param", i would like to remove that. how can i do that?

Capture.PNG

 

this is the snippet of relevant code:

 

graph = panel Box();

Build_chart = Function( {param},
	gb = dt1 << Graph Builder(
		Size( 1024, 725 ),
		Show Control Panel( 0 ),
		Auto Stretching( 0 ),
		Automatic Recalc( 1 ),
		Variables( X( :pm_start_date ), Y( :task_value ),Group X( :parameter ),
		Elements( Points( X, Y, Legend( 1 ), Jitter( 1 ) ), Smoother( X, Y, Legend( 2 ) ) ),
		Where( :parameter == param ) 

	)
			
);

For( j = 1, j <= N Items( param_list ), j++,
	graph << append( Report( Build_chart( param_list[j] ) ) )
);

 
chartreport = New Window( "test ",
	ob = H List Box( graph)
);

Thanks in advanced!

 

 

3 REPLIES 3
txnelson
Super User

Re: how to remove "Where" from graph builder report window

All you need to do, is to find the top of the display tree, and then delete the first text box, which is the display of the Where clause.  See below

graph = panel Box();

Build_chart = Function( {param},
	gb = dt1 << Graph Builder(
		Size( 1024, 725 ),
		Show Control Panel( 0 ),
		Auto Stretching( 0 ),
		Automatic Recalc( 1 ),
		Variables(
			X( :pm_start_date ),
			Y( :task_value ),
			Group X( :parameter ),
			Elements( Points( X, Y, Legend( 1 ), Jitter( 1 ) ), Smoother( X, Y, Legend( 2 ) ) ),
			Where( :parameter == param )
		)
	);
	tp = Report( gb ) << topparent;
	tp[Text Box( 1 )] << delete;
);

For( j = 1, j <= N Items( param_list ), j++,
	graph << append( Report( Build_chart( param_list[j] ) ) )
);

 
chartreport = New Window( "test ",
	ob = H List Box( graph)
);
Jim
samshaw
Level I

Re: how to remove "Where" from graph builder report window

amazing!! it worked!!

 

this is the part i was missing

<<topparent;

 what does it do?

 

thank you again!

txnelson
Super User

Re: how to remove "Where" from graph builder report window

The definition, taken from the Scripting Index, for Top Parent is

 

Returns the root parent of the Display Box

Jim