<?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: Selecting rows and then further selecting based on that in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/Selecting-rows-and-then-further-selecting-based-on-that/m-p/291050#M55610</link>
    <description>&lt;P&gt;Your original premise does not work the way you think it does.&amp;nbsp; &amp;lt;&amp;lt;get values does not just return values from selected rows.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Here is an example that works using a selection criteria, that should be pretty efficient.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;names default to here(1);
dt=open("$SAMPLE_DATA/big class.jmp");

dt &amp;lt;&amp;lt; select where(:weight &amp;lt;100);
dt &amp;lt;&amp;lt; hide and exclude;

dt_rgt = dt &amp;lt;&amp;lt; Summary(
	Group( :name ),
	Freq( "None" ),
	Weight( "None" ),
	link to original data table(1)
);

dt_rgt &amp;lt;&amp;lt; delete rows;
dt &amp;lt;&amp;lt; clear rowstates;
dt_rgt &amp;lt;&amp;lt; select all rows;

close( dt_rgt, nosave);&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Thu, 27 Aug 2020 16:13:57 GMT</pubDate>
    <dc:creator>txnelson</dc:creator>
    <dc:date>2020-08-27T16:13:57Z</dc:date>
    <item>
      <title>Selecting rows and then further selecting based on that</title>
      <link>https://community.jmp.com/t5/Discussions/Selecting-rows-and-then-further-selecting-based-on-that/m-p/289606#M55584</link>
      <description>&lt;P&gt;I have a data table where I can select rows based on one columns result.&amp;nbsp; I would like to then expand that selection based on a value contained in the previously selected rows.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I tried&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;dt = Current Data Table();
dr &amp;lt;&amp;lt; select where( :ctrlrange &amp;gt; 0.23 );
h = Column( dt, "reagentkit_id" ) &amp;lt;&amp;lt; get Values;
dt &amp;lt;&amp;lt; select where( :reagentkit_id == h );&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;That didnt seem to work as JMP froze.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The data table could have a lot of lines.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The reason I want to do this is that certain times the ctrlrange is higher than 0.23 and I want all data from reagent (where the ctrl range may not have been higher than 0.23)&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 09 Jun 2023 23:36:08 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Selecting-rows-and-then-further-selecting-based-on-that/m-p/289606#M55584</guid>
      <dc:creator>UberBock</dc:creator>
      <dc:date>2023-06-09T23:36:08Z</dc:date>
    </item>
    <item>
      <title>Re: Selecting rows and then further selecting based on that</title>
      <link>https://community.jmp.com/t5/Discussions/Selecting-rows-and-then-further-selecting-based-on-that/m-p/289643#M55585</link>
      <description>&lt;P&gt;I saw the 'expand' in the select but could not figure out how to expand based on the previous selection from a value in another column of that selection.&lt;/P&gt;</description>
      <pubDate>Thu, 27 Aug 2020 00:45:06 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Selecting-rows-and-then-further-selecting-based-on-that/m-p/289643#M55585</guid>
      <dc:creator>UberBock</dc:creator>
      <dc:date>2020-08-27T00:45:06Z</dc:date>
    </item>
    <item>
      <title>Re: Selecting rows and then further selecting based on that</title>
      <link>https://community.jmp.com/t5/Discussions/Selecting-rows-and-then-further-selecting-based-on-that/m-p/289709#M55587</link>
      <description>&lt;P&gt;I believe this is what you want&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;dt=current data table();

// You have a typo.....you are specifying dr and it should be dt....I assume
//dr&amp;lt;&amp;lt;select where(:ctrlrange&amp;gt;0.23);
dt&amp;lt;&amp;lt;select where(:ctrlrange&amp;gt;0.23);

h=Column(dt, "reagentkit_id")&amp;lt;&amp;lt;get Values;


dt&amp;lt;&amp;lt;select where(contains(h,:reagentkit_id);&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 27 Aug 2020 02:43:39 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Selecting-rows-and-then-further-selecting-based-on-that/m-p/289709#M55587</guid>
      <dc:creator>txnelson</dc:creator>
      <dc:date>2020-08-27T02:43:39Z</dc:date>
    </item>
    <item>
      <title>Re: Selecting rows and then further selecting based on that</title>
      <link>https://community.jmp.com/t5/Discussions/Selecting-rows-and-then-further-selecting-based-on-that/m-p/290811#M55597</link>
      <description>&lt;P&gt;It was a typo when I made the forum post.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I am trying&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;dt = Current Data Table();

dt &amp;lt;&amp;lt; select where( :ctrlrange &amp;gt; 0.23 );

h = Column( dt, "reagentkit_id" ) &amp;lt;&amp;lt; get Values;

dt &amp;lt;&amp;lt; select where( Contains( h, :reagentkit_id ) );&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Using it on a table that has over 2.9mil lines JMP does not respond.&amp;nbsp; I take it this is an intensive process&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 27 Aug 2020 13:11:04 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Selecting-rows-and-then-further-selecting-based-on-that/m-p/290811#M55597</guid>
      <dc:creator>UberBock</dc:creator>
      <dc:date>2020-08-27T13:11:04Z</dc:date>
    </item>
    <item>
      <title>Re: Selecting rows and then further selecting based on that</title>
      <link>https://community.jmp.com/t5/Discussions/Selecting-rows-and-then-further-selecting-based-on-that/m-p/290813#M55598</link>
      <description>If the list "h" is real long, then it will be a very intensive script.  I would suggest that you create a summary data table grouping on your :reagentkit_id column. Make sure you have the "Link to original data table" selected, and then select all rows in the Summary Table.  The link to the original table, will force all of the matches from the summary table to be selected in the original table.</description>
      <pubDate>Thu, 27 Aug 2020 13:12:12 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Selecting-rows-and-then-further-selecting-based-on-that/m-p/290813#M55598</guid>
      <dc:creator>txnelson</dc:creator>
      <dc:date>2020-08-27T13:12:12Z</dc:date>
    </item>
    <item>
      <title>Re: Selecting rows and then further selecting based on that</title>
      <link>https://community.jmp.com/t5/Discussions/Selecting-rows-and-then-further-selecting-based-on-that/m-p/290954#M55605</link>
      <description>&lt;P&gt;Good Idea.&lt;BR /&gt;&lt;BR /&gt;I tried this&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;dt = Current Data Table();
dt &amp;lt;&amp;lt; select where( :ctrlrange &amp;gt; 0.23 );
h = Column( dt, "reagentkit_id" ) &amp;lt;&amp;lt; get Values;

dt_rgt = dt &amp;lt;&amp;lt; Summary(
    Group( :reagentkit_id ),
    N Catagories( :reagentkit_id ),
    Freq( "None" ),
    Weight( "None" ),
    Link to original data table( 1 )
);
dt_rgt &amp;lt;&amp;lt; select where( Contains( h, :reagentkit_id ) );&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&lt;BR /&gt;It created a summary table that was linked. But it selected all rows in the original data table. Not kust the lines of data that had the reagentkit_id that was selected because one of its :ctrlrange was over 0.23.&lt;BR /&gt;&lt;BR /&gt;If I comment out dt_rgt &amp;lt;&amp;lt; select where( Contains( h, :reagentkit_id ) ); it works. Meaning that in a small table with 2,150 rows it picks out the 6 lines that have the ctrlrange being greater than 0.23 and it makes the summary table.&lt;/P&gt;</description>
      <pubDate>Thu, 27 Aug 2020 17:47:52 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Selecting-rows-and-then-further-selecting-based-on-that/m-p/290954#M55605</guid>
      <dc:creator>UberBock</dc:creator>
      <dc:date>2020-08-27T17:47:52Z</dc:date>
    </item>
    <item>
      <title>Re: Selecting rows and then further selecting based on that</title>
      <link>https://community.jmp.com/t5/Discussions/Selecting-rows-and-then-further-selecting-based-on-that/m-p/290994#M55608</link>
      <description>Should i select the lines with the ctrlrange greater than 0.23. Then subset into another table and then use that table to select the reagentkit_id from the original table?</description>
      <pubDate>Thu, 27 Aug 2020 15:28:46 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Selecting-rows-and-then-further-selecting-based-on-that/m-p/290994#M55608</guid>
      <dc:creator>UberBock</dc:creator>
      <dc:date>2020-08-27T15:28:46Z</dc:date>
    </item>
    <item>
      <title>Re: Selecting rows and then further selecting based on that</title>
      <link>https://community.jmp.com/t5/Discussions/Selecting-rows-and-then-further-selecting-based-on-that/m-p/291030#M55609</link>
      <description>&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;dt = Current Data Table();
dt &amp;lt;&amp;lt; select where( :ctrlrange &amp;gt; 0.23 );
dt &amp;lt;&amp;lt; Subset( Output Table( "Sel" ), Selected Rows( 1 ), selected Columns( 0 ) );
dt_rgt = dt &amp;lt;&amp;lt; Summary(
    Group( :reagentkit_id ),
    N Catagories( :reagentkit_id ),
    Freq( "None" ),
    Weight( "None" ),
    Link to original data table( 1 )
);

//h = Column( Sel, "reagentkit_id" ) &amp;lt;&amp;lt; get Values;

dt_rgt &amp;lt;&amp;lt; select where( Contains( Sel, :reagentkit_id ) );&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&lt;BR /&gt;Not sure how to indicate that it should select where looks at the Sel table for the values to select in the dt_rgt table.&lt;BR /&gt;&lt;BR /&gt;Any ideas??&lt;/P&gt;</description>
      <pubDate>Thu, 27 Aug 2020 17:48:43 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Selecting-rows-and-then-further-selecting-based-on-that/m-p/291030#M55609</guid>
      <dc:creator>UberBock</dc:creator>
      <dc:date>2020-08-27T17:48:43Z</dc:date>
    </item>
    <item>
      <title>Re: Selecting rows and then further selecting based on that</title>
      <link>https://community.jmp.com/t5/Discussions/Selecting-rows-and-then-further-selecting-based-on-that/m-p/291050#M55610</link>
      <description>&lt;P&gt;Your original premise does not work the way you think it does.&amp;nbsp; &amp;lt;&amp;lt;get values does not just return values from selected rows.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Here is an example that works using a selection criteria, that should be pretty efficient.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;names default to here(1);
dt=open("$SAMPLE_DATA/big class.jmp");

dt &amp;lt;&amp;lt; select where(:weight &amp;lt;100);
dt &amp;lt;&amp;lt; hide and exclude;

dt_rgt = dt &amp;lt;&amp;lt; Summary(
	Group( :name ),
	Freq( "None" ),
	Weight( "None" ),
	link to original data table(1)
);

dt_rgt &amp;lt;&amp;lt; delete rows;
dt &amp;lt;&amp;lt; clear rowstates;
dt_rgt &amp;lt;&amp;lt; select all rows;

close( dt_rgt, nosave);&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 27 Aug 2020 16:13:57 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Selecting-rows-and-then-further-selecting-based-on-that/m-p/291050#M55610</guid>
      <dc:creator>txnelson</dc:creator>
      <dc:date>2020-08-27T16:13:57Z</dc:date>
    </item>
  </channel>
</rss>

