cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Choose Language Hide Translation Bar

Graph Builder - Overlay by multiple columns

I would like to have Graph Builder be able to Overlay by several variables in the same way that x, y or color drop-zones can take several variables. This would allow overlay to be selected/deselected from the "Variables" group under each graph type and create much more complex and rich visualizations.

13 Comments
gzmorgan0
Super User (Alumni)

Currently,  there are methods that might meet your needs today:

  • Add a column switcher to your report that switches out the Overlay Variables,
  • Create a new Column, or transform a column to be a concatenation, and
  • for an additional level of control especially for nested overlay variables add a Local Data Filter

Row Switcher example

image.png

 

Transformed column example

image.png

 

 

Script for the transformed column example:

Graph Builder(
	Size( 491, 454 ),
	Show Control Panel( 0 ),
	Variables(
		X( :Robbery ),
		Y( :Population ),
		Overlay(
			Transform Column(
				"Region, State",
				Character,
				Nominal,
				Formula( :Region || ", " || :State )
			)
		)
	),
	Elements( Points( X, Y, Legend( 1 ) ), Smoother( X, Y, Legend( 2 ) ) ),
	Local Data Filter(
		Add Filter(
			columns( :Region ),
			Where( :Region == "Midwest" ),
			Display( :Region, Size( 160, 120 ), List Display )
		)
	)
)

 

morenopelaez_p
Level III

Thanks @gzmorgan0 , indeed, it can be achieved in several ways but I consider those "workarounds" ... I am more looking for the feature to have multiple fields in overlay, the same way that it was implemented for Color some time ago.

BHarris
Level VI

This is a great request and is something I often find myself wanting as well.  

 

Part of the reason is that the Overlay can be used with line plots to break the lines.  I often find myself wanting to break the lines when any of 2 or 3 variables change, but in order to do that I have to concatenate the columns together in the data table, which is a little clunky.

hogi
Level XII

Would be really nice to have this feature!


@XanGregg: Is there a reason why it is not possible to use several columns as overlay - and, for each subplot,  to pick the desired column via "variables" (like it is possible for all the other settings).

 

Surprisingly, it IS possible (via JSL) - 
the Overlay dropzone shows both columns and in the variables list the user can pick the Overlay column he wants - the left plot uses sex (red, blue = F/M), the right plot uses age (green/purple = 12 / 13 years):

hogi_0-1726475302800.png


... but looking closer, the result is not like expected ...

Unfortunately, the overlay by "age" on the right looks exactly like the overlay by "sex" (on the left)  -- just with different colors.

 

 

Names Default to Here(1);
dt = Open( "$SAMPLE_DATA/Big Class.jmp" );
Graph Builder(
	Variables(
		X( :height ),
		X( :height ),
		Y( :weight ),
		Overlay( :sex ),
		Overlay( :age )
	),
	Elements(
		Position( 1, 1 ),
		Points( X, Y, Legend( 1 ) ),
		Smoother( X, Y, Legend( 2 ) )
	),
	Elements(
		Position( 2, 1 ),
		Points( X, Y, Overlay( 2 ) ),
		Smoother( X, Y, Overlay( 2 ) )
	)
);

[edit: plot is no easier to understand]

hogi
Level XII

related wish: Graph Builder: support more than 2 'Color' columns 

(>2 Colors instead of >1 Overlays)

hogi
Level XII

@Sarah-Sylvestre : an old wish with a lot of potential.

Attribute is stilll "new".

Are Jmp Developers investigating if this is possible?

Status changed to: Acknowledged

Hi @hogi, thank you for bringing this to my attention! Status should be acknowledged so I am updating it. This has been investigated but we have had several higher priority items that need to be worked on take precedence. I will check in on this item and update this wish if it becomes a higher priority relative to our other development work. 

 
hogi
Level XII
twiindley
Level I

I also run into this need constantly.  Would be wonderful to have this feature!

hogi
Level XII

 Graph Builder: support more than 2 'Color' columns 
got "accepted"

my best wishes for this wish here ...