Hi,
I am plotting 64 histogram distributions and stack them together. I like to change the color of each histogram different. You can manually do this but how one can change this automatically?
I appreciate your help. Thanks
The Histogram Color is programatically available to JSL. You can fairly easily write a script to do this. Here is the result of just using Customize and then having the platform generate the script for the modification
Distribution( Stack( 1 ), Continuous Distribution( Column( :height ), Horizontal Layout( 1 ), Vertical( 0 ) ), Continuous Distribution( Column( :weight ), Horizontal Layout( 1 ), Vertical( 0 ) ), SendToReport( Dispatch( {"height"}, "Distrib Histogram", FrameBox, {DispatchSeg( Hist Seg( 1 ), {Line Color( {108, 60, 65} ), Fill Color( "Medium Light Green" )} )} ), Dispatch( {"weight"}, "Distrib Histogram", FrameBox, {DispatchSeg( Hist Seg( 1 ), {Line Color( {108, 60, 65} ), Fill Color( "Red" )} )} ) ) );
Thanks Jim. Does it mean I have to do this for 64 Histograms that I want to build and stack them together?
The simple answer is yes......however, using a For() loop and Substitution you can just loop through the 64 histograms you want and generate the necessary code
Thanks Jim. I will give it a try.