cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Try the Materials Informatics Toolkit, which is designed to easily handle SMILES data. This and other helpful add-ins are available in the JMP® Marketplace
%3CLINGO-SUB%20id%3D%22lingo-sub-659599%22%20slang%3D%22en-US%22%20mode%3D%22NONE%22%3E%ED%9E%88%ED%8A%B8%EB%A7%B5%20%ED%94%8C%EB%A1%AF%20-%20%EC%83%89%EC%83%81%20%ED%98%BC%ED%95%A9%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-659599%22%20slang%3D%22en-US%22%20mode%3D%22NONE%22%3E%3CP%3EBigClass%EC%97%90%EC%84%9C%20%EC%99%B8%EA%B3%84%EC%9D%B8%EC%9D%84%20%EA%B2%80%EC%83%89%ED%95%98%EB%A9%B4%EC%84%9C%20%EC%98%A4%EB%8A%98%EC%9D%80%20%EC%99%B8%EA%B3%84%EC%9D%B8%EC%9D%84%20%ED%95%9C%20%EB%88%88%EC%97%90%20%EB%B3%BC%20%EC%88%98%20%EC%9E%88%EB%8A%94%20%ED%9E%88%ED%8A%B8%EB%A7%B5%20%ED%94%8C%EB%A1%AF%EC%9D%84%20%EC%83%9D%EC%84%B1%ED%95%98%EB%A0%A4%EA%B3%A0%20%ED%95%A9%EB%8B%88%EB%8B%A4.%3C%2FP%3E%3CP%3E%EC%95%84%EC%9D%B4%EB%94%94%EC%96%B4%3A%20%EC%99%B8%EA%B3%84%EC%9D%B8%EC%9D%B4%20%EC%95%84%EB%8B%8C%20%ED%95%99%EC%83%9D%EC%9D%80%20%EB%85%B9%EC%83%89%EC%9C%BC%EB%A1%9C%2C%20%EC%99%B8%EA%B3%84%EC%9D%B8%EC%9D%80%20%EB%B9%A8%EA%B0%84%EC%83%89%EC%9C%BC%EB%A1%9C%20%EC%83%89%EC%B9%A0%ED%95%A9%EB%8B%88%EB%8B%A4.%3C%2FP%3E%3CP%3E%EA%B7%B8%EB%9F%AC%EB%82%98%20%EA%B0%99%EC%9D%80%20%EC%97%B0%EB%A0%B9%20%EA%B7%B8%EB%A3%B9%EC%97%90%20%EC%9E%88%EB%8A%94%20%EC%97%AC%EB%9F%AC%20%EB%B9%84%EC%99%B8%EA%B3%84%EC%9D%B8%EC%9D%98%20%EA%B2%BD%EC%9A%B0%20%EC%99%B8%EA%B3%84%EC%9D%B8%20%EB%B9%A8%EA%B0%84%EC%83%89%EC%9D%B4%20%EC%95%BD%EA%B0%84%EB%A7%8C%20%EB%B3%B4%EC%9E%85%EB%8B%88%EB%8B%A4.%3C%2FP%3E%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22hogi_3-1689680051325.png%22%20style%3D%22width%3A%20400px%3B%22%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22hogi_3-1689680051325.png%22%20style%3D%22width%3A%20370px%3B%22%3E%3Cspan%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22hogi_3-1689680051325.png%22%20style%3D%22width%3A%20370px%3B%22%3E%3Cimg%20src%3D%22https%3A%2F%2Fcommunity.jmp.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F54845i7299D74F0C0D3773%2Fimage-size%2Fmedium%3Fv%3Dv2%26amp%3Bpx%3D400%22%20role%3D%22button%22%20title%3D%22hogi_3-1689680051325.png%22%20alt%3D%22hogi_3-1689680051325.png%22%20%2F%3E%3C%2Fspan%3E%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%EB%8B%A4%EC%9D%8C%20%EC%95%84%EC%9D%B4%EB%94%94%EC%96%B4%3A%3CBR%20%2F%3E%20%EC%99%B8%EA%B3%84%EC%9D%B8%EC%9D%B4%20%EC%9E%88%EB%8A%94%20%EC%97%B0%EB%A0%B9%EB%8C%80%EA%B0%80%20%EC%9E%98%20%EB%B3%B4%EC%9D%B4%EB%8F%84%EB%A1%9D%20%EB%B9%84%EC%99%B8%EA%B3%84%EC%9D%B8%EC%97%90%20%EB%8C%80%ED%95%9C%20%ED%88%AC%EB%AA%85%EB%8F%84%EB%A5%BC%20%EB%86%92%EC%9D%B4%EC%9E%90.%3CBR%20%2F%3E%20%EB%82%98%EB%8A%94%20%EA%B7%B8%EB%9F%AC%ED%95%9C%20%EC%84%B8%ED%8F%AC%EA%B0%80%20%EB%B9%A8%EA%B0%84%EC%83%89(%EC%9D%BC%EB%B6%80%20%EB%85%B9%EC%83%89%20%ED%84%B0%EC%B9%98%EC%99%80%20%ED%95%A8%EA%BB%98)%EC%9D%84%20%EC%96%BB%EC%9D%84%20%EA%B2%83%EC%9C%BC%EB%A1%9C%20%EC%98%88%EC%83%81%ED%96%88%EC%A7%80%EB%A7%8C%20%EB%B9%A8%EA%B0%84%EC%83%89%EC%9D%B4%20%EC%95%84%EB%8B%88%EB%9D%BC%20%EC%83%81%EB%8B%B9%ED%9E%88%20%EB%85%B9%EC%83%89%EC%9E%85%EB%8B%88%EB%8B%A4.%3CBR%20%2F%3E%20%EC%83%89%EC%83%81%EB%B3%84%EB%A1%9C%20%ED%88%AC%EB%AA%85%EB%8F%84%EB%A5%BC%20%EB%94%B0%EB%A1%9C%20%EC%B2%98%EB%A6%AC%ED%95%98%EC%A7%80%20%EC%95%8A%EB%8A%94%20%EA%B2%83%20%EA%B0%99%EC%A7%80%EB%A7%8C%2C%3CSTRONG%3E%20%ED%98%BC%ED%95%A9%3C%2FSTRONG%3E%20%EB%BF%90%EB%A7%8C%20%EC%95%84%EB%8B%88%EB%9D%BC%20%ED%98%BC%ED%95%A9%20%EC%83%89%EC%83%81%EC%97%90%20%EC%A0%81%EC%9A%A9%EB%90%A9%EB%8B%88%EB%8B%A4.%3C%2FP%3E%3CP%3E%EB%94%B0%EB%9D%BC%EC%84%9C%205%25%20%EB%85%B9%EC%83%89%20%2B%20100%25%20%EB%B9%A8%EA%B0%84%EC%83%89%EC%9D%80%3C%2FP%3E%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22hogi_2-1689680046296.png%22%20style%3D%22width%3A%20400px%3B%22%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22hogi_2-1689680046296.png%22%20style%3D%22width%3A%20370px%3B%22%3E%3Cspan%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22hogi_2-1689680046296.png%22%20style%3D%22width%3A%20370px%3B%22%3E%3Cimg%20src%3D%22https%3A%2F%2Fcommunity.jmp.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F54844iF88EFB04E361276B%2Fimage-size%2Fmedium%3Fv%3Dv2%26amp%3Bpx%3D400%22%20role%3D%22button%22%20title%3D%22hogi_2-1689680046296.png%22%20alt%3D%22hogi_2-1689680046296.png%22%20%2F%3E%3C%2Fspan%3E%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%EB%A7%88%EC%A7%80%EB%A7%89%20%EC%8B%9C%EB%8F%84%3A%3CBR%20%2F%3E%20%EB%8D%B0%EC%9D%B4%ED%84%B0%20%EC%9C%A0%ED%98%95%EC%9D%84%20%EB%B3%80%EA%B2%BD%ED%95%98%EA%B3%A0%20%EC%B5%9C%EB%8C%80%20%EC%9A%94%EC%95%BD%20%ED%86%B5%EA%B3%84%EB%A5%BC%20%EC%82%AC%EC%9A%A9%ED%95%98%EC%8B%AD%EC%8B%9C%EC%98%A4.%3C%2FP%3E%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22hogi_4-1689680624330.png%22%20style%3D%22width%3A%20400px%3B%22%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22hogi_4-1689680624330.png%22%20style%3D%22width%3A%20388px%3B%22%3E%3Cspan%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22hogi_4-1689680624330.png%22%20style%3D%22width%3A%20388px%3B%22%3E%3Cimg%20src%3D%22https%3A%2F%2Fcommunity.jmp.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F54846i9651105DB79ED68D%2Fimage-size%2Fmedium%3Fv%3Dv2%26amp%3Bpx%3D400%22%20role%3D%22button%22%20title%3D%22hogi_4-1689680624330.png%22%20alt%3D%22hogi_4-1689680624330.png%22%20%2F%3E%3C%2Fspan%3E%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%EC%97%AC%EA%B8%B0%EC%B2%98%EB%9F%BC%20%EC%A7%91%EA%B3%84%ED%95%98%EB%A0%A4%EB%8A%94%20%EA%B2%BD%EC%9A%B0%20%EB%AC%B8%EC%9E%90%EC%97%90%EC%84%9C%20%EC%88%AB%EC%9E%90%EB%A1%9C%20%EC%A0%84%ED%99%98%ED%95%98%EB%8A%94%20%EA%B2%83%EC%9D%B4%20%EB%8D%94%20%EC%89%AC%EC%9A%B4%20%EA%B2%BD%EC%9A%B0%EB%8F%84%20%EC%9E%88%EC%8A%B5%EB%8B%88%EB%8B%A4.%3CBR%20%2F%3E%20%EA%B7%B8%EB%9F%AC%EB%82%98%20%EB%AC%B8%EC%9E%90%20%EA%B0%92%EC%9D%98%20%EC%A7%91%EA%B3%84%EC%97%90%EB%8A%94%20%EB%8B%A4%EC%9D%8C%EA%B3%BC%20%EA%B0%99%EC%9D%80%20%EA%B0%80%EB%8A%A5%EC%84%B1%EB%8F%84%20%EC%9E%88%EC%8A%B5%EB%8B%88%EB%8B%A4.%3C%2FP%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Fcommunity.jmp.com%2Ft5%2FJMP-Wish-List%2FSummary-and-Tabulate-add-aggregation-option-for-Character%2Fm-p%2F659314%23U659314%22%20class%3D%22lia-mention-container-editor-message%20lia-img-icon-idea-thread%20lia-fa-icon%20lia-fa-idea%20lia-fa-thread%20lia-fa%22%20target%3D%22_blank%22%3E%EC%9A%94%EC%95%BD%20%EB%B0%8F%20%EB%8F%84%ED%91%9C%ED%99%94%3A%20%EB%AC%B8%EC%9E%90%20%EC%97%B4%EC%97%90%20%EB%8C%80%ED%95%9C%20%EC%A7%91%EA%B3%84%20%EC%98%B5%EC%85%98%20%EC%B6%94%EA%B0%80%3C%2FA%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CPRE%3E%3CCODE%20class%3D%22%20language-jsl%22%3ENames%20Default%20To%20Here(%201%20)%3B%0Adt%20%3D%20Open(%20%22%24SAMPLE_DATA%2FBig%20Class.jmp%22%20)%3B%0Adt%20%26lt%3B%26lt%3B%20New%20Column(%20%22alien%22%2C%20Character%2Cnominal%2C%20set%20each%20value(%20%22-%22%20)%20)%3B%0Adt%20%26lt%3B%26lt%3B%20add%20rows(%20%7Bname%20%3D%20%22XX%22%2C%20alien%20%3D%20%22alien%22%2C%20sex%20%3D%20%22M%22%2C%20age%20%3D%2015%7D%20)%3B%0Adt%20%26lt%3B%26lt%3B%20add%20rows(%20%7Bname%20%3D%20%22YZ%22%2C%20alien%20%3D%20%22alien%22%2C%20sex%20%3D%20%22F%22%2C%20age%20%3D%2012%7D%20)%3B%0Adt%20%26lt%3B%26lt%3B%20add%20rows(%20%7Bname%20%3D%20%22KR%22%2C%20alien%20%3D%20%22alien%22%2C%20sex%20%3D%20%22F%22%2C%20age%20%3D%2017%7D%20)%3B%0A%0A%0A%2F%2F%20first%20attempt%0Adt%20%26lt%3B%26lt%3B%20Graph%20Builder(%0A%20Variables(%20X(%20%3Asex%20)%2C%20Y(%20%3Aage%20)%2C%20Color(%20%3Aalien%20)%20)%2C%0A%20Elements(%20Heatmap(%20X%2C%20Y%2C%20Legend(%2010%20)%20)%20)%2C%0A%20SendToReport(%0A%20%20Dispatch(%7B%7D%2C%22400%22%2CScaleBox%2C%0A%20%20%20%7BLegend%20Model(%2010%2C%20Properties(%200%2C%20%7BFill%20Color(%2036%20)%7D%2C%20Item%20ID(%20%22-%22%2C%201%20)%20)%20)%7D%0A%20%20)%0A%20)%0A)%3B%0A%0A%2F%2F%20second%20attempt%3A%20increase%20transparency%20for%20non-aliens%0Adt%20%26lt%3B%26lt%3B%20Graph%20Builder(%0A%20Variables(%20X(%20%3Asex%20)%2C%20Y(%20%3Aage%20)%2C%20Color(%20%3Aalien%20)%20)%2C%0A%20Elements(%20Heatmap(%20X%2C%20Y%2C%20Legend(%2010%20)%20)%20)%2C%0A%20SendToReport(%0A%20%20Dispatch(%0A%20%20%20%7B%7D%2C%0A%20%20%20%22400%22%2C%0A%20%20%20ScaleBox%2C%0A%20%20%20%7BLegend%20Model(%2010%2C%20Properties(%200%2C%20%7BFill%20Color(%2036%20)%2C%20Transparency(%200.05%20)%7D%2C%20Item%20ID(%20%22-%22%2C%201%20)%20)%20)%7D%0A%20%20)%0A%20)%0A)%3B%0A%0A%2F%2F%203rd%20attempt%3A%20aggregate%0AGraph%20Builder(%0A%20Variables(%0A%20%20X(%20%3Asex%20)%2C%0A%20%20Y(%20%3Aage%20)%2C%0A%20%20Color(%20%3Aalien_num%2C%20Summary%20Statistic(%20%22Max%22%20)%20)%0A%20)%2C%0A%20Elements(%20Heatmap(%20X%2C%20Y%2C%20Legend(%2010%20)%20)%20)%2C%0A%20SendToReport(%0A%20%20Dispatch(%0A%20%20%20%7B%7D%2C%0A%20%20%20%22400%22%2C%0A%20%20%20ScaleBox%2C%0A%20%20%20%7BLegend%20Model(%0A%20%20%20%2010%2C%0A%20%20%20%20Properties(%200%2C%20%7BFill%20Color(%2036%20)%7D%2C%20Item%20ID(%20%220%22%2C%201%20)%20)%0A%20%20%20)%7D%0A%20%20)%0A%20)%0A)%3C%2FCODE%3E%3C%2FPRE%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-659599%22%20slang%3D%22en-US%22%20mode%3D%22NONE%22%3E%3CLINGO-LABEL%3E%EB%8D%B0%EC%9D%B4%ED%84%B0%20%ED%98%BC%ED%95%A9%20%EB%B0%8F%20%EC%A0%95%EB%A6%AC%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3E%EB%8D%B0%EC%9D%B4%ED%84%B0%20%ED%83%90%EC%83%89%20%EB%B0%8F%20%EC%8B%9C%EA%B0%81%ED%99%94%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E
Choose Language Hide Translation Bar
hogi
Level XII

Heatmap Plot - mixing colors

In my search for aliens in BigClass, today I want to generate a heatmap plot to show the aliens at a glance.

The idea: color the non-alien students green and the aliens red.

But with several non-aliens in the same age group, the alien red is just slightly visible:

hogi_3-1689680051325.png

 

Next idea:
Let's increase the transparency for non-aliens such that age groups with aliens inside get nicely visible.
I exected such cells to get red (with some greenish touch) - but they are quite green, not red.
Seems that transparency is not treated separately for different colors, but mixed as well and then applied to the mixed color.

So, 5% green + 100% red gives 

hogi_2-1689680046296.png

last attempt:
change the data type and use Max summary Statistics:

hogi_4-1689680624330.png

Sometimes it's easier to switch from character to numbers, if you want to aggregate - like here.
But aggregation of character values has also some potential:

Summary and Tabulate: add aggregation option for Character columns 

 

 

Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA/Big Class.jmp" );
dt << New Column( "alien", Character,nominal, set each value( "-" ) );
dt << add rows( {name = "XX", alien = "alien", sex = "M", age = 15} );
dt << add rows( {name = "YZ", alien = "alien", sex = "F", age = 12} );
dt << add rows( {name = "KR", alien = "alien", sex = "F", age = 17} );


// first attempt
dt << Graph Builder(
	Variables( X( :sex ), Y( :age ), Color( :alien ) ),
	Elements( Heatmap( X, Y, Legend( 10 ) ) ),
	SendToReport(
		Dispatch({},"400",ScaleBox,
			{Legend Model( 10, Properties( 0, {Fill Color( 36 )}, Item ID( "-", 1 ) ) )}
		)
	)
);

// second attempt: increase transparency for non-aliens
dt << Graph Builder(
	Variables( X( :sex ), Y( :age ), Color( :alien ) ),
	Elements( Heatmap( X, Y, Legend( 10 ) ) ),
	SendToReport(
		Dispatch(
			{},
			"400",
			ScaleBox,
			{Legend Model( 10, Properties( 0, {Fill Color( 36 ), Transparency( 0.05 )}, Item ID( "-", 1 ) ) )}
		)
	)
);

// 3rd attempt: aggregate
Graph Builder(
	Variables(
		X( :sex ),
		Y( :age ),
		Color( :alien_num, Summary Statistic( "Max" ) )
	),
	Elements( Heatmap( X, Y, Legend( 10 ) ) ),
	SendToReport(
		Dispatch(
			{},
			"400",
			ScaleBox,
			{Legend Model(
				10,
				Properties( 0, {Fill Color( 36 )}, Item ID( "0", 1 ) )
			)}
		)
	)
)

 

 

0 REPLIES 0