Subscribe Bookmark RSS Feed

Exclude Grouping values in nested groups in graph builder.

vince_faller

Super User

Joined:

Mar 17, 2015

I have a heat map that needs some nested groups (in order to properly show values inside the heat map) squares.  My issue is that a lot of the rows are entirely missing because it forces every group to exist.  Is there a way to only show valid groups?  For example:

 

Names Default to here(1);
dt = open("$SAMPLE_DATA\Big Class.jmp");

rows = dt << Get Rows Where(:age == 14 & :sex == "M");
dt << delete rows(rows);

dt << Graph Builder(
	Variables( Group Y( :sex ), Group Y( :age ), Color( :height ) ),
	Elements( Heatmap( Legend( 4 ) ), Caption Box( Legend( 5 ) ) )
);

Gives. 

 

3-14-2017 4-26-44 PM.png

 

I don't want to see the 14 year old Male category.  

 

Or, if you know a better way to show the means for a column inside the square, I'd take that too. 

 

 

 

2 REPLIES
John_Powell_JMP

Joined:

May 30, 2014

Would labeled bars work?

dt << Graph Builder(
	Size( 456, 413 ),
	Show Control Panel( 0 ),
	Variables( X( :height ), Y( :sex ), Y( :age, Position( 1 ) ), Color( :height ) ),
	Elements( Bar( X, Y( 1 ), Y( 2 ), Legend( 5 ), Label( "Label by Value" ) ) ),
	SendToReport( Dispatch( {}, "sex", ScaleBox, {Reversed Scale} ) )
);

LabeledNestedBars.PNG

 

vince_faller

Super User

Joined:

Mar 17, 2015

No because in actuality it's a 2d array.  More like this.  

 

3-24-2017 10-56-15 AM.png