cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
The Discovery Summit 2025 Call for Content is open! Submit an abstract today to present at our premier analytics conference.
See how to use JMP Live to centralize and share reports within groups. Webinar with Q&A April 4, 2pm ET.
Choose Language Hide Translation Bar
View Original Published Thread

How do I get my colors to stay consistent for bar graphs when using filters - using JMP 17.2.0

GLynnWarren
Level I

I have established value colors for the column, using Column Properties>Value Colors.  I have built it into a script, similar to this.

dt:"(Group)Type"n << Set Property(
Value Colors,
{"("A" = 16, "B" = 24, "C" = 56, "D" = 8, "E" = 40, "F" = 72, and so on. (There are 36 total cell values that I am identifying in the list)

Then I run the script for the graph

dt << Graph Builder(
	Size(1460, 625),
	Show Control Panel(0),
	Legend Position("Right"),
	Level Spacing Color("Medium Light Gray"),
	Graph Spacing(5),
	Spacing Borders(1),
	Variables(X(:Year), X(:Qtr, Position(1)), Y(:"(Group)Type"n), Group X(:Location)),
	Elements(Mosaic(X(1), X(2), Y, Legend(7), Cell Labeling("Label by Percent"))),
	Local Data Filter(Conditional, Add Filter(columns(:Location, :Year)))
);

Edit 2024-07-31 (jthi): added jsl formatting using <JSL> button

 

It will generally run with the colors I expected, but if using the filters, the colors may change - some of the colors remain as expected.  As though it is ignoring the column properties set for the value.

Is there a limit on the number of column values you can specify a particular column color? 

I have made changes through the process to make sure I'm not using the same color number to more than just one value.

JMP 17.2.0

 

1 REPLY 1
jthi
Super User


Re: How do I get my colors to stay consistent for bar graphs when using filters - using JMP 17.2.0

Are you sure value colors are set properly for all values? Also, try if adding (Group)Type column to Color helps.

-Jarmo