<?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: JMP Scripting Coloring Cells Based on a Criteria in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/JMP-Scripting-Coloring-Cells-Based-on-a-Criteria/m-p/466228#M71001</link>
    <description>&lt;P&gt;Thank you so much! It worked.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;As a follow up question, if I wanted to create an indicator column with a 1 to mark any row with a highlighted cell in the data table, how can I do that?&lt;/P&gt;</description>
    <pubDate>Wed, 02 Mar 2022 15:29:48 GMT</pubDate>
    <dc:creator>dn610</dc:creator>
    <dc:date>2022-03-02T15:29:48Z</dc:date>
    <item>
      <title>JMP Scripting Coloring Cells Based on a Criteria</title>
      <link>https://community.jmp.com/t5/Discussions/JMP-Scripting-Coloring-Cells-Based-on-a-Criteria/m-p/465886#M70970</link>
      <description>&lt;P&gt;Hi - Can someone please tell me how I would go about coloring a cell that is not equal to 1 in the summary sheet below using JMP Scripting, starting with the N Categories (Process Taxonomy Level 1) column? Also, these are just sample columns, there are 40 other columns so I don't want to specify the actual column names in the script. Lastly, If a cell is colored in the summary table, can the color be applied to the original data table, to which the summary table is linked?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="dn610_0-1646152790711.png" style="width: 400px;"&gt;&lt;img src="https://community.jmp.com/t5/image/serverpage/image-id/40402i1B83AA49FE188E37/image-size/medium?v=v2&amp;amp;px=400" role="button" title="dn610_0-1646152790711.png" alt="dn610_0-1646152790711.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 10 Jun 2023 23:45:03 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/JMP-Scripting-Coloring-Cells-Based-on-a-Criteria/m-p/465886#M70970</guid>
      <dc:creator>dn610</dc:creator>
      <dc:date>2023-06-10T23:45:03Z</dc:date>
    </item>
    <item>
      <title>Re: JMP Scripting Coloring Cells Based on a Criteria</title>
      <link>https://community.jmp.com/t5/Discussions/JMP-Scripting-Coloring-Cells-Based-on-a-Criteria/m-p/465936#M70972</link>
      <description>&lt;P&gt;Here is one way to handle the issue:&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="txnelson_0-1646156136944.png" style="width: 400px;"&gt;&lt;img src="https://community.jmp.com/t5/image/serverpage/image-id/40406i57F04959FCAF4CFE/image-size/medium?v=v2&amp;amp;px=400" role="button" title="txnelson_0-1646156136944.png" alt="txnelson_0-1646156136944.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default To Here( 1 );
// Open Data Table: big class.jmp
// → Data Table( "big class" )
dt = Open( "$SAMPLE_DATA/big class.jmp" );

 dtSum = dt &amp;lt;&amp;lt; Summary(
	Group( :age ),
	Mean( :height ),
	Mean( :weight ),
	Freq( "None" ),
	Weight( "None" ),
	statistics column name format( "column" )
);

// Get the column names of the current columns
sumColNames = dtSum &amp;lt;&amp;lt; get column names(string);

// Remove the first 2 columns from the list
remove from( sumColNames, 1, 2 );

// loop across columns finding all cells &amp;gt; 63
For( i=1, i&amp;lt;= N Items( sumColNames ), i++,
	// select all rows where cells are above 63
	dtSum &amp;lt;&amp;lt; select where( as column( dtSum, sumColNames[i]) &amp;gt; 63 );
	
	// Color cells in summary table
	as column(dtSum, sumColNames[i]) &amp;lt;&amp;lt; Color Cells( red, dtSum &amp;lt;&amp;lt; get selected rows );
	// Color cells in original table
	as column(dt, sumColNames[i]) &amp;lt;&amp;lt; Color Cells( red, dt &amp;lt;&amp;lt; get selected rows );
)

&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 01 Mar 2022 17:36:16 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/JMP-Scripting-Coloring-Cells-Based-on-a-Criteria/m-p/465936#M70972</guid>
      <dc:creator>txnelson</dc:creator>
      <dc:date>2022-03-01T17:36:16Z</dc:date>
    </item>
    <item>
      <title>Re: JMP Scripting Coloring Cells Based on a Criteria</title>
      <link>https://community.jmp.com/t5/Discussions/JMP-Scripting-Coloring-Cells-Based-on-a-Criteria/m-p/466228#M71001</link>
      <description>&lt;P&gt;Thank you so much! It worked.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;As a follow up question, if I wanted to create an indicator column with a 1 to mark any row with a highlighted cell in the data table, how can I do that?&lt;/P&gt;</description>
      <pubDate>Wed, 02 Mar 2022 15:29:48 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/JMP-Scripting-Coloring-Cells-Based-on-a-Criteria/m-p/466228#M71001</guid>
      <dc:creator>dn610</dc:creator>
      <dc:date>2022-03-02T15:29:48Z</dc:date>
    </item>
    <item>
      <title>Re: JMP Scripting Coloring Cells Based on a Criteria</title>
      <link>https://community.jmp.com/t5/Discussions/JMP-Scripting-Coloring-Cells-Based-on-a-Criteria/m-p/466256#M71004</link>
      <description>&lt;OL&gt;
&lt;LI&gt;Read the documents, Discovering JMP and Using JMP.&amp;nbsp; Both documents are in the JMP Documentation Library available under the Help pull down menu.&lt;/LI&gt;
&lt;LI&gt;To add an indicator column
&lt;OL&gt;
&lt;LI&gt;Create a new column in both the original data table, and in the summary data table.&amp;nbsp; Call the column "Flag" or "Indicator" etc.&lt;/LI&gt;
&lt;LI&gt;Add to the script, as the last 2 lines in the For() loop
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;dt:Flag[dt &amp;lt;&amp;lt; get selected rows]=1;
dtSum:Flag[dtSum &amp;lt;&amp;lt; get selected rows]=1;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;/LI&gt;
&lt;/OL&gt;
&lt;/LI&gt;
&lt;LI&gt;Take the time to study the script to make sure you understand it.&lt;/LI&gt;
&lt;/OL&gt;</description>
      <pubDate>Wed, 02 Mar 2022 16:37:29 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/JMP-Scripting-Coloring-Cells-Based-on-a-Criteria/m-p/466256#M71004</guid>
      <dc:creator>txnelson</dc:creator>
      <dc:date>2022-03-02T16:37:29Z</dc:date>
    </item>
    <item>
      <title>Re: JMP Scripting Coloring Cells Based on a Criteria</title>
      <link>https://community.jmp.com/t5/Discussions/JMP-Scripting-Coloring-Cells-Based-on-a-Criteria/m-p/466296#M71007</link>
      <description>&lt;P&gt;Thank you so much!&lt;/P&gt;</description>
      <pubDate>Wed, 02 Mar 2022 18:26:38 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/JMP-Scripting-Coloring-Cells-Based-on-a-Criteria/m-p/466296#M71007</guid>
      <dc:creator>dn610</dc:creator>
      <dc:date>2022-03-02T18:26:38Z</dc:date>
    </item>
  </channel>
</rss>

