<?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 Tabulate script to use all columns as grouping columns in Row Table in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/Tabulate-script-to-use-all-columns-as-grouping-columns-in-Row/m-p/191526#M41076</link>
    <description>&lt;P&gt;I am still fairly novice with JSL but I am looking to generate a table using all the columns in a file as grouping columns, where the script will select all the columns in the file vs. having identify each column name in the script.&amp;nbsp; Reason being is that the column names can change from split table to split table and I want a script that will be generic enough to handle this.&amp;nbsp; Here is an example of the script I am using now&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;// Open dialog box to select SWR Table&lt;BR /&gt;project &amp;lt;&amp;lt; Run Script(&lt;BR /&gt;Files = Pick File( "Select SWR Table", "$DESKTOP", {"JMP Files|xlsx", "All Files|*"}, 1, 0, "", "multiple" );&lt;BR /&gt;For( i = 1, i &amp;lt;= N Items( Files ), i++,&lt;BR /&gt;Try(&lt;BR /&gt;Open(&lt;BR /&gt;Files[i],&lt;BR /&gt;Worksheet Settings( Has Column Headers( 1 ), Number of Rows in Headers( 1 ), Headers Start on Row( 1 ),&lt;BR /&gt;Data Starts on Row( 2 ) )&lt;BR /&gt;)&lt;BR /&gt;)&lt;BR /&gt;);&lt;BR /&gt;Bring Window To Front&lt;BR /&gt;);&lt;/P&gt;&lt;P&gt;//Create SWR Table - TBD&lt;BR /&gt;project &amp;lt;&amp;lt; Run Script(&lt;BR /&gt;obj = Tabulate( Add Table( Row Table( Grouping Columns( &lt;STRONG&gt;:WAFER, :EPI Run&lt;/STRONG&gt; ) ) ),Include missing for grouping columns(1) )&lt;BR /&gt;);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I want to substitue out the individual columns in "Grouping Columns" to use all the columns from the table without having to specify each one.&amp;nbsp; Is this possible?&lt;/P&gt;</description>
    <pubDate>Fri, 05 Apr 2019 20:28:13 GMT</pubDate>
    <dc:creator>Chilly</dc:creator>
    <dc:date>2019-04-05T20:28:13Z</dc:date>
    <item>
      <title>Tabulate script to use all columns as grouping columns in Row Table</title>
      <link>https://community.jmp.com/t5/Discussions/Tabulate-script-to-use-all-columns-as-grouping-columns-in-Row/m-p/191526#M41076</link>
      <description>&lt;P&gt;I am still fairly novice with JSL but I am looking to generate a table using all the columns in a file as grouping columns, where the script will select all the columns in the file vs. having identify each column name in the script.&amp;nbsp; Reason being is that the column names can change from split table to split table and I want a script that will be generic enough to handle this.&amp;nbsp; Here is an example of the script I am using now&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;// Open dialog box to select SWR Table&lt;BR /&gt;project &amp;lt;&amp;lt; Run Script(&lt;BR /&gt;Files = Pick File( "Select SWR Table", "$DESKTOP", {"JMP Files|xlsx", "All Files|*"}, 1, 0, "", "multiple" );&lt;BR /&gt;For( i = 1, i &amp;lt;= N Items( Files ), i++,&lt;BR /&gt;Try(&lt;BR /&gt;Open(&lt;BR /&gt;Files[i],&lt;BR /&gt;Worksheet Settings( Has Column Headers( 1 ), Number of Rows in Headers( 1 ), Headers Start on Row( 1 ),&lt;BR /&gt;Data Starts on Row( 2 ) )&lt;BR /&gt;)&lt;BR /&gt;)&lt;BR /&gt;);&lt;BR /&gt;Bring Window To Front&lt;BR /&gt;);&lt;/P&gt;&lt;P&gt;//Create SWR Table - TBD&lt;BR /&gt;project &amp;lt;&amp;lt; Run Script(&lt;BR /&gt;obj = Tabulate( Add Table( Row Table( Grouping Columns( &lt;STRONG&gt;:WAFER, :EPI Run&lt;/STRONG&gt; ) ) ),Include missing for grouping columns(1) )&lt;BR /&gt;);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I want to substitue out the individual columns in "Grouping Columns" to use all the columns from the table without having to specify each one.&amp;nbsp; Is this possible?&lt;/P&gt;</description>
      <pubDate>Fri, 05 Apr 2019 20:28:13 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Tabulate-script-to-use-all-columns-as-grouping-columns-in-Row/m-p/191526#M41076</guid>
      <dc:creator>Chilly</dc:creator>
      <dc:date>2019-04-05T20:28:13Z</dc:date>
    </item>
    <item>
      <title>Re: Tabulate script to use all columns as grouping columns in Row Table</title>
      <link>https://community.jmp.com/t5/Discussions/Tabulate-script-to-use-all-columns-as-grouping-columns-in-Row/m-p/191568#M41080</link>
      <description>&lt;P&gt;I think this is what you want.&amp;nbsp; It should create a new tabulate table for each data table read in&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;// Open dialog box to select SWR Table
project &amp;lt;&amp;lt; Run Script(
	Files = Pick File(
		"Select SWR Table",
		"$DESKTOP",
		{"JMP Files|xlsx", "All Files|*"},
		1,
		0,
		"",
		"multiple"
	);
	For( i = 1, i &amp;lt;= N Items( Files ), i++,
		Try(
			dt=Open(
				Files[i],
				Worksheet Settings(
					Has Column Headers( 1 ),
					Number of Rows in Headers( 1 ),
					Headers Start on Row( 1 ),
					Data Starts on Row( 2 )
				)
			)
		);
		dt &amp;lt;&amp;lt; rerun formulas;
		colList = dt &amp;lt;&amp;lt; get column names( nominal );
		obj = dt &amp;lt;&amp;lt; Tabulate(
		Add Table( Row Table( Grouping Columns( evalexpr(colList) ) ) ),
		Include missing for grouping columns( 1 )
	)
	);
	Bring Window To Front;
);
//Create SWR Table - TBD
/*project &amp;lt;&amp;lt; Run Script(
	obj = Tabulate(
		Add Table( Row Table( Grouping Columns( :WAFER, :EPI Run ) ) ),
		Include missing for grouping columns( 1 )
	)
);*/&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Sat, 06 Apr 2019 03:35:49 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Tabulate-script-to-use-all-columns-as-grouping-columns-in-Row/m-p/191568#M41080</guid>
      <dc:creator>txnelson</dc:creator>
      <dc:date>2019-04-06T03:35:49Z</dc:date>
    </item>
  </channel>
</rss>

