cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
  • Don’t miss your chance to experience Discovery Summit Europe at our best available rate! Early bird registration through 31 Oct.
  • Graph Builder Toolbar streamlines interactive graphing. Creates shortcuts on Report and GraphBuilder Helpers toolbars. Download and install the extension.
  • JMP will suspend normal business operations for our Rest and Recharge Day on Friday, October 2, 2026.
    Regular business hours will resume on Monday, October 5, 2026.

Discussions

Solve problems, and share tips and tricks with other JMP users.
Choose Language Hide Translation Bar
hogi
Level XIII

Packed Chart

For Graph Builder/Bar/Packed chart, how can I change the way how items are selected as "primary labels"?
By default the highest values of the first framebox are used, right?
Can I change it to: highest values summed over all frameboxes?

e.g.for cars data

dt = Open( "$SAMPLE_DATA/Cars.jmp" );
gb  = Graph Builder(
	Variables( X( :Make ), Group X( :Year ), Color( :Make ) ),
	Elements(
		Bar(
			X,
			Legend( 6 ),
			Bar Style( "Packed" ),
			Packed Primaries( 5 ),
			Packed Primary Labels( "On axis" ),
			Summary Statistic( "Max" )
		)
	)
);

there are many entries with :Make==Toyota, but the first FrameBox (year= 87)  just contains 4 x Toyota - and T comes too late in the alphabet. So Dodge and Hyundai win "the race":

dt << select  where(:Make == "Toyota");
(gb << xpath("//FrameBox"))  << Fill Selection Mode( "Selected Outlined" )

hogi_1-1735405538482.png

1 REPLY 1
hogi
Level XIII

Re: Packed Chart

Using Column properties  / value order, I can adjust the order - to manually get Toyota into the primary labels:

:make << Set Property( "Value Order", {Custom Order( {"Toyota"} )} )

hogi_0-1735406909833.png

.. . at position #4.

If I want to apply the same trick for Mitsubishi, it fails  - too few entries in 1987:

hogi_1-1735407120844.png

:make << Delete Property( "Value Order" ) << Set Property( "Value Order", {Custom Order( {"Mitsubishi"} )} )

Recommended Articles