cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
  • Instantly extract effect sizes, F-ratios, and FDR-adjusted p-values from your models with the Calculate Effects Sizes extension, available now in the JMP Marketplace!
  • New to JMP? Join us Sept. 23-24 for the Early User Edition of Discovery Summit, tailor-made for new users. Register now for free!
  • Your voice matters! Tell us how you prefer to receive JMP updates, so we can tailor our communication to your needs. Take short survey.

Discussions

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

Color Histograms with By statement in Distribution

I am trying to use distribution to create histograms By(: DeviceID), However when I apply the fill color only the last graph in the By statement gets changed to light blue. No matter what I do, only the last graph changes color. I just want the graphs to not be green.

Options that work for me:

1) color histograms by device ID

2) color histograms both to be blue

saneal_0-1624643795700.png

 

WaferRgPastMonth << Distribution(
	Stack( 1 ),
	Automatic Recalc( 1 ),
	Continuous Distribution( Column( :Rg ), Horizontal Layout( 1 ), Vertical( 0 ) ),
	By( :DeviceID ),
	Local Data Filter( Close Outline( 1 ), Add Filter( columns( :FailDie ), Where( :FailDie == 0 ) ) ),
	SendToReport(
		Dispatch( {"Rg"}, "Distrib Outlier Box", FrameBox, {Frame Size( 350, 46 )} ),
		Dispatch(
			{"Rg"},
			"Distrib Histogram",
			FrameBox,
			{Frame Size( 277, 110 ), DispatchSeg( Hist Seg( 1 ), {Line Color( {56, 82, 112} ), Fill Color( "Light Blue" )} )}
		)
	)
);

 

1 ACCEPTED SOLUTION

Accepted Solutions
txnelson
Super User

Re: Color Histograms with By statement in Distribution

If you restructure your code, you will be able to set the histograms to the color you want

txnelson_0-1624646949664.png

names default to here(1);
// Open Data Table: big class.jmp
// → Data Table( "big class" )
dt = Open( "$SAMPLE_DATA/big class.jmp" );
dis = dt << Distribution(
	Stack( 1 ),
	Continuous Distribution(
		Column( :weight ),
		Quantiles( 0 ),
		Summary Statistics( 0 ),
		Horizontal Layout( 1 ),
		Vertical( 0 )
	),
	By( :Sex )
);
dis<<histogram color("blue");

 

Jim

View solution in original post

2 REPLIES 2
txnelson
Super User

Re: Color Histograms with By statement in Distribution

If you restructure your code, you will be able to set the histograms to the color you want

txnelson_0-1624646949664.png

names default to here(1);
// Open Data Table: big class.jmp
// → Data Table( "big class" )
dt = Open( "$SAMPLE_DATA/big class.jmp" );
dis = dt << Distribution(
	Stack( 1 ),
	Continuous Distribution(
		Column( :weight ),
		Quantiles( 0 ),
		Summary Statistics( 0 ),
		Horizontal Layout( 1 ),
		Vertical( 0 )
	),
	By( :Sex )
);
dis<<histogram color("blue");

 

Jim
saneal
Level III

Re: Color Histograms with By statement in Distribution

Thank you so much!!

Recommended Articles