<?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 give multiple inputs for column selection in jsl in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/How-to-give-multiple-inputs-for-column-selection-in-jsl/m-p/246161#M48357</link>
    <description>&lt;P&gt;You can expand on the If() condition that you are evaluating, into the 3 comparisons you want.&amp;nbsp; I believe the below code will get you what you need&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default To Here( 1 );
dt = Current Data Table();

colList = dt &amp;lt;&amp;lt; Get Column Names( Numeric, "Continuous" );

For( i = 1, i &amp;lt;= N Cols( dt ), i++,
	If( Contains( colList[i], "NPT_IRST_" ) | 
		Contains( colList[i], "_NPT" ) |
		Contains( colList[i], "[" ) 
		,
		Column( colList[i] ) &amp;lt;&amp;lt; Set Selected( 1 )
	)
);&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Thu, 06 Feb 2020 04:34:06 GMT</pubDate>
    <dc:creator>txnelson</dc:creator>
    <dc:date>2020-02-06T04:34:06Z</dc:date>
    <item>
      <title>How to give multiple inputs for column selection in jsl</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-give-multiple-inputs-for-column-selection-in-jsl/m-p/246155#M48356</link>
      <description>&lt;P&gt;Hi!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm trying to use the contains function to select multiple columns. After going through the scripting guide, I found an example which gave me a direction, but I don't know how to give multiple inputs. Here's the section of code I'm using:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;dt = current data table();

colList = dt &amp;lt;&amp;lt; Get Column Names(Numeric, "Continuous");

For( i = 1, i &amp;lt;= N Cols( dt ), i++,
	If( Contains( colList[i],"NPT_IRST_"),
		Column( colList[i] ) &amp;lt;&amp;lt; Set Selected( 1 )
	)
);&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;I need to give the following inputs: &lt;STRONG&gt;"NPT_IRST_"&lt;/STRONG&gt; ,&lt;STRONG&gt; "_NPT"&lt;/STRONG&gt; and&lt;STRONG&gt; [&lt;/STRONG&gt; ( open square bracket). How do I give these three inputs?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;</description>
      <pubDate>Thu, 06 Feb 2020 04:01:17 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-give-multiple-inputs-for-column-selection-in-jsl/m-p/246155#M48356</guid>
      <dc:creator>D_T_M</dc:creator>
      <dc:date>2020-02-06T04:01:17Z</dc:date>
    </item>
    <item>
      <title>Re: How to give multiple inputs for column selection in jsl</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-give-multiple-inputs-for-column-selection-in-jsl/m-p/246161#M48357</link>
      <description>&lt;P&gt;You can expand on the If() condition that you are evaluating, into the 3 comparisons you want.&amp;nbsp; I believe the below code will get you what you need&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default To Here( 1 );
dt = Current Data Table();

colList = dt &amp;lt;&amp;lt; Get Column Names( Numeric, "Continuous" );

For( i = 1, i &amp;lt;= N Cols( dt ), i++,
	If( Contains( colList[i], "NPT_IRST_" ) | 
		Contains( colList[i], "_NPT" ) |
		Contains( colList[i], "[" ) 
		,
		Column( colList[i] ) &amp;lt;&amp;lt; Set Selected( 1 )
	)
);&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 06 Feb 2020 04:34:06 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-give-multiple-inputs-for-column-selection-in-jsl/m-p/246161#M48357</guid>
      <dc:creator>txnelson</dc:creator>
      <dc:date>2020-02-06T04:34:06Z</dc:date>
    </item>
    <item>
      <title>Re: How to give multiple inputs for column selection in jsl</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-give-multiple-inputs-for-column-selection-in-jsl/m-p/246174#M48359</link>
      <description>Thank you so much for your help!!&lt;BR /&gt;&lt;BR /&gt;As a quick followup, if I try to stack the selected columns in the above case, I'm using the following:&lt;BR /&gt;&lt;BR /&gt;dt &amp;lt;&amp;lt; stack(&lt;BR /&gt;column(colList),&lt;BR /&gt;Source Label Column( "Label" ),&lt;BR /&gt;Stacked Data Column( "Data" )&lt;BR /&gt;);&lt;BR /&gt;&lt;BR /&gt;but for some reason, It doesn't stack the selected columns. Any suggestion on how to solve this?</description>
      <pubDate>Thu, 06 Feb 2020 05:15:22 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-give-multiple-inputs-for-column-selection-in-jsl/m-p/246174#M48359</guid>
      <dc:creator>D_T_M</dc:creator>
      <dc:date>2020-02-06T05:15:22Z</dc:date>
    </item>
  </channel>
</rss>

