<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: How to denote letters to mark significant differences in a boxplot? in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/How-to-denote-letters-to-mark-significant-differences-in-a/m-p/551536#M76736</link>
    <description>&lt;P&gt;I think you would have to:&lt;/P&gt;
&lt;OL&gt;
&lt;LI&gt;Calculate those letters (based on my 5second googling those letters are from Tukey's test, so I just used some Connecting Letters Report)&lt;/LI&gt;
&lt;LI&gt;Create new column which will map those letters to correct rows&lt;/LI&gt;
&lt;LI&gt;Use that column as marker&lt;/LI&gt;
&lt;LI&gt;Add points to the graph builder&lt;/LI&gt;
&lt;LI&gt;Use suitable summary statistic for points plot to show them in good location (might require new column to create some offset)&lt;/LI&gt;
&lt;LI&gt;Markers should be shown in the graph&lt;/LI&gt;
&lt;/OL&gt;
&lt;P&gt;You could most likely also combine steps 2-6 into graphic script&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Here is fairly simple example with Big Class using non graphic script option:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default To Here(1);

dt = Open("$SAMPLE_DATA/Big Class.jmp");

fit = dt &amp;lt;&amp;lt; Oneway(Y(:height), X(:age), All Pairs(1), invisible);
letters_tb = ((Report(fit)[OutlineBox("Connecting Letters Report")]) &amp;lt;&amp;lt; child) &amp;lt;&amp;lt; child;

tb_letter_cols = Filter Each({col_name}, letters_tb &amp;lt;&amp;lt; Get Names,
	Starts With(col_name, "~Letter Column ")
);

aa_letters = Associative Array();
For Each({level, idx}, letters_tb[1] &amp;lt;&amp;lt; get,
	aa_letters[level] = "";
	For Each({letter_col, idx_col}, tb_letter_cols,
		aa_letters[level] ||= letters_tb[1 + idx_col][idx];
	);
);
fit &amp;lt;&amp;lt; close window;

dt &amp;lt;&amp;lt; New Column("TukeyLetters", Character, Nominal, UseForMarker(1), &amp;lt;&amp;lt; Set Each Value(
	aa_letters[char(:age)];
));

gb = dt &amp;lt;&amp;lt; Graph Builder(
	Size(529, 451),
	Show Control Panel(0),
	Variables(X(:age), Y(:height)),
	Elements(
		Box Plot(X, Y, Legend(6), Box Style("Solid"), Fences(0)),
		Points(
			X,
			Y,
			Legend(7),
			Summary Statistic("Third Quartile"),
			Error Interval("None")
		)
	)
);
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="jthi_2-1664619883003.png" style="width: 400px;"&gt;&lt;img src="https://community.jmp.com/t5/image/serverpage/image-id/45954i804E2162999F7DB3/image-size/medium?v=v2&amp;amp;px=400" role="button" title="jthi_2-1664619883003.png" alt="jthi_2-1664619883003.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Edit:&lt;/P&gt;
&lt;P&gt;Created wish list item for this&amp;nbsp;&lt;LI-MESSAGE title="Display letters of significance in graph builder when using boxplot and in fit y by x when comparison is performed" uid="551541" url="https://community.jmp.com/t5/JMP-Wish-List/Display-letters-of-significance-in-graph-builder-when-using/m-p/551541#U551541" discussion_style_icon_css="lia-mention-container-editor-message lia-img-icon-idea-thread lia-fa-icon lia-fa-idea lia-fa-thread lia-fa"&gt;&lt;/LI-MESSAGE&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Sat, 01 Oct 2022 10:42:32 GMT</pubDate>
    <dc:creator>jthi</dc:creator>
    <dc:date>2022-10-01T10:42:32Z</dc:date>
    <item>
      <title>How to denote letters to mark significant differences in a boxplot?</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-denote-letters-to-mark-significant-differences-in-a/m-p/543793#M76267</link>
      <description>&lt;P&gt;Hi! I have JMP Pro 14. I´m creating several boxplots where I want to show the significant differences between categories with letters above the Q3 like in this graph:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="MagaSganga_0-1663024172470.png" style="width: 400px;"&gt;&lt;img src="https://community.jmp.com/t5/image/serverpage/image-id/45397iF338FBA9329185DD/image-size/medium?v=v2&amp;amp;px=400" role="button" title="MagaSganga_0-1663024172470.png" alt="MagaSganga_0-1663024172470.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;How can I put the letters a and b above the boxes? My plot is this one:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="MagaSganga_0-1663024426631.png" style="width: 400px;"&gt;&lt;img src="https://community.jmp.com/t5/image/serverpage/image-id/45399iAE69E78F0F03667A/image-size/medium?v=v2&amp;amp;px=400" role="button" title="MagaSganga_0-1663024426631.png" alt="MagaSganga_0-1663024426631.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Mi Graph Builder code is:&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Graph Builder(
	Size( 571, 448 ),
	Show Control Panel( 0 ),
	Show Legend( 0 ),
	Show Title( 0 ),
	Show Footer( 0 ),
	Variables( X( :Cat ), Y( :Name( "Pl/min" ) ) ),
	Elements( Box Plot( X, Y, Legend( 6 ), Box Style( "Solid" ) ) ),
	SendToReport(
		Dispatch(
			{},
			"Cat",
			ScaleBox,
			{Reversed Scale, Label Row(
				{Set Font Size( 12 ), Tick Mark( Label( "6" ), Label( "6 " ) ),
				Tick Mark( Label( "7" ), Label( "7 " ) )}
			)}
		),
		Dispatch(
			{},
			"Pl/min",
			ScaleBox,
			{Min( 5.5 ), Max( 18 ), Inc( 2 ), Minor Ticks( 1 )}
		),
		Dispatch(
			{},
			"400",
			ScaleBox,
			{Legend Model(
				6,
				Properties(
					0,
					{Line Color( 32 ), Fill Color( 0 )},
					Item ID( "Pl/min", 1 )
				)
			)}
		),
		Dispatch( {}, "X title", TextEditBox, {Set Font Size( 12 )} ),
		Dispatch( {}, "Y title", TextEditBox, {Set Font Size( 12 )} ),
		Dispatch(
			{},
			"Graph Builder",
			FrameBox,
			{DispatchSeg(
				Box Plot Seg( "Box Plot (4)" ),
				{Line Color( {128, 128, 128} ), Fill Color( "Medium Dark Red" )}
			), DispatchSeg(
				Box Plot Seg( "Box Plot (5)" ),
				{Line Color( {128, 128, 128} ), Fill Color( "Medium Dark Yellow" )}
			), DispatchSeg(
				Box Plot Seg( "Box Plot (6)" ),
				{Line Color( "Medium Dark Yellow" ),
				Fill Color( "Medium Dark Green" )}
			), DispatchSeg(
				Box Plot Seg( "Box Plot (7)" ),
				{Line Color( "Medium Dark Yellow" ),
				Fill Color( "Medium Dark BlueCyan" )}
			), DispatchSeg(
				Box Plot Seg( "Box Plot (8)" ),
				{Line Color( "Medium Dark Yellow" ),
				Fill Color( "Medium Dark Magenta" )}
			), DispatchSeg(
				Box Plot Seg( "Box Plot (9)" ),
				{Line Color( "Medium Dark Purple" ),
				Fill Color( "Medium Dark Fuchsia" )}
			)}
		)
	)
);&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Thanks in advance.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Magali.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 11 Jun 2023 11:27:40 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-denote-letters-to-mark-significant-differences-in-a/m-p/543793#M76267</guid>
      <dc:creator>MagaSganga</dc:creator>
      <dc:date>2023-06-11T11:27:40Z</dc:date>
    </item>
    <item>
      <title>Re: How to denote letters to mark significant differences in a boxplot?</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-denote-letters-to-mark-significant-differences-in-a/m-p/551536#M76736</link>
      <description>&lt;P&gt;I think you would have to:&lt;/P&gt;
&lt;OL&gt;
&lt;LI&gt;Calculate those letters (based on my 5second googling those letters are from Tukey's test, so I just used some Connecting Letters Report)&lt;/LI&gt;
&lt;LI&gt;Create new column which will map those letters to correct rows&lt;/LI&gt;
&lt;LI&gt;Use that column as marker&lt;/LI&gt;
&lt;LI&gt;Add points to the graph builder&lt;/LI&gt;
&lt;LI&gt;Use suitable summary statistic for points plot to show them in good location (might require new column to create some offset)&lt;/LI&gt;
&lt;LI&gt;Markers should be shown in the graph&lt;/LI&gt;
&lt;/OL&gt;
&lt;P&gt;You could most likely also combine steps 2-6 into graphic script&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Here is fairly simple example with Big Class using non graphic script option:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default To Here(1);

dt = Open("$SAMPLE_DATA/Big Class.jmp");

fit = dt &amp;lt;&amp;lt; Oneway(Y(:height), X(:age), All Pairs(1), invisible);
letters_tb = ((Report(fit)[OutlineBox("Connecting Letters Report")]) &amp;lt;&amp;lt; child) &amp;lt;&amp;lt; child;

tb_letter_cols = Filter Each({col_name}, letters_tb &amp;lt;&amp;lt; Get Names,
	Starts With(col_name, "~Letter Column ")
);

aa_letters = Associative Array();
For Each({level, idx}, letters_tb[1] &amp;lt;&amp;lt; get,
	aa_letters[level] = "";
	For Each({letter_col, idx_col}, tb_letter_cols,
		aa_letters[level] ||= letters_tb[1 + idx_col][idx];
	);
);
fit &amp;lt;&amp;lt; close window;

dt &amp;lt;&amp;lt; New Column("TukeyLetters", Character, Nominal, UseForMarker(1), &amp;lt;&amp;lt; Set Each Value(
	aa_letters[char(:age)];
));

gb = dt &amp;lt;&amp;lt; Graph Builder(
	Size(529, 451),
	Show Control Panel(0),
	Variables(X(:age), Y(:height)),
	Elements(
		Box Plot(X, Y, Legend(6), Box Style("Solid"), Fences(0)),
		Points(
			X,
			Y,
			Legend(7),
			Summary Statistic("Third Quartile"),
			Error Interval("None")
		)
	)
);
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="jthi_2-1664619883003.png" style="width: 400px;"&gt;&lt;img src="https://community.jmp.com/t5/image/serverpage/image-id/45954i804E2162999F7DB3/image-size/medium?v=v2&amp;amp;px=400" role="button" title="jthi_2-1664619883003.png" alt="jthi_2-1664619883003.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Edit:&lt;/P&gt;
&lt;P&gt;Created wish list item for this&amp;nbsp;&lt;LI-MESSAGE title="Display letters of significance in graph builder when using boxplot and in fit y by x when comparison is performed" uid="551541" url="https://community.jmp.com/t5/JMP-Wish-List/Display-letters-of-significance-in-graph-builder-when-using/m-p/551541#U551541" discussion_style_icon_css="lia-mention-container-editor-message lia-img-icon-idea-thread lia-fa-icon lia-fa-idea lia-fa-thread lia-fa"&gt;&lt;/LI-MESSAGE&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 01 Oct 2022 10:42:32 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-denote-letters-to-mark-significant-differences-in-a/m-p/551536#M76736</guid>
      <dc:creator>jthi</dc:creator>
      <dc:date>2022-10-01T10:42:32Z</dc:date>
    </item>
  </channel>
</rss>

