<?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: Finding row index as a number in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/Finding-row-index-as-a-number/m-p/16318#M14872</link>
    <description>&lt;P&gt;Slight modification to your syntax:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;rmat = dt &amp;lt;&amp;lt; get rows where (as column(2) == 0);&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Mon, 06 Nov 2017 14:44:18 GMT</pubDate>
    <dc:creator>pmroz</dc:creator>
    <dc:date>2017-11-06T14:44:18Z</dc:date>
    <item>
      <title>Finding row index as a number</title>
      <link>https://community.jmp.com/t5/Discussions/Finding-row-index-as-a-number/m-p/16317#M14871</link>
      <description>&lt;P&gt;hi all.&lt;/P&gt;
&lt;P&gt;I need to find row index when column2 =0&lt;/P&gt;
&lt;P&gt;and then use the row number in subset.&lt;/P&gt;
&lt;P&gt;when I use "select where" or "get where" it doesn't give me the index as a number.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;dt&amp;lt;&amp;lt;get rows where( :column (2)==0);&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&lt;SPAN style="color: #000080; font-size: 14pt; font-family: Consolas;"&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 06 Nov 2017 14:43:56 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Finding-row-index-as-a-number/m-p/16317#M14871</guid>
      <dc:creator>razmah</dc:creator>
      <dc:date>2017-11-06T14:43:56Z</dc:date>
    </item>
    <item>
      <title>Re: Finding row index as a number</title>
      <link>https://community.jmp.com/t5/Discussions/Finding-row-index-as-a-number/m-p/16318#M14872</link>
      <description>&lt;P&gt;Slight modification to your syntax:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;rmat = dt &amp;lt;&amp;lt; get rows where (as column(2) == 0);&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 06 Nov 2017 14:44:18 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Finding-row-index-as-a-number/m-p/16318#M14872</guid>
      <dc:creator>pmroz</dc:creator>
      <dc:date>2017-11-06T14:44:18Z</dc:date>
    </item>
    <item>
      <title>Re: Finding row index as a number</title>
      <link>https://community.jmp.com/t5/Discussions/Finding-row-index-as-a-number/m-p/16319#M14873</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;it shows:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;rmat = [](0, 1);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;what does this mean? I need just a number. for example 90. (means in row #90)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 13 Jan 2016 19:56:20 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Finding-row-index-as-a-number/m-p/16319#M14873</guid>
      <dc:creator>razmah</dc:creator>
      <dc:date>2016-01-13T19:56:20Z</dc:date>
    </item>
    <item>
      <title>Re: Finding row index as a number</title>
      <link>https://community.jmp.com/t5/Discussions/Finding-row-index-as-a-number/m-p/16320#M14874</link>
      <description>&lt;P&gt;Run this:&lt;/P&gt;
&lt;P class="p1"&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;dt=New Table( "example table",
  Add Rows( 12 ), New Column( "A column", Numeric, "Continuous",
  Set Values( [1, 1, 1, 10, 0, 1, 1, 1, 0, 1, 0, 1] )  ));
rmat = dt &amp;lt;&amp;lt; get rows where (as column(1) == 0);&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P class="p4"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P class="p4"&gt;in the log you'll see this:&lt;/P&gt;
&lt;P&gt;&lt;STRONG style="font-size: 10pt; line-height: 1.5em;"&gt;[5, 9, 11]&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;this is a list of rows where the first column was equal to 0;&lt;/P&gt;</description>
      <pubDate>Mon, 06 Nov 2017 14:44:49 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Finding-row-index-as-a-number/m-p/16320#M14874</guid>
      <dc:creator>Byron_JMP</dc:creator>
      <dc:date>2017-11-06T14:44:49Z</dc:date>
    </item>
    <item>
      <title>Re: Finding row index as a number</title>
      <link>https://community.jmp.com/t5/Discussions/Finding-row-index-as-a-number/m-p/16321#M14875</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;rmat is a row matrix.&amp;nbsp; To get the number of rows you can write &lt;STRONG&gt;n = NRows(rmat)&lt;/STRONG&gt;.&amp;nbsp; The first row number will be &lt;STRONG&gt;rmat[1]&lt;/STRONG&gt;, the second &lt;STRONG&gt;rmat[2]&lt;/STRONG&gt; up to&lt;STRONG&gt; rmat&lt;N&gt;&lt;/N&gt;&lt;/STRONG&gt;.&amp;nbsp; If you want to look up corresponding values in another column, just for these rows you can write &lt;STRONG&gt;Column("data")[rmat] &amp;lt;&amp;lt; Get Values&lt;/STRONG&gt;.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 14 Jan 2016 10:06:10 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Finding-row-index-as-a-number/m-p/16321#M14875</guid>
      <dc:creator>David_Burnham</dc:creator>
      <dc:date>2016-01-14T10:06:10Z</dc:date>
    </item>
    <item>
      <title>Re: Finding row index as a number</title>
      <link>https://community.jmp.com/t5/Discussions/Finding-row-index-as-a-number/m-p/16322#M14876</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Your result indicates there were no rows meeting your criteria. If you know there are rows with 0 in them, it may be that your column is character data type and the comparison is numeric... either put quotes around 0 in your comparison, or change the data type of the column to Numeric. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 14 Jan 2016 15:57:11 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Finding-row-index-as-a-number/m-p/16322#M14876</guid>
      <dc:creator>jerry_cooper</dc:creator>
      <dc:date>2016-01-14T15:57:11Z</dc:date>
    </item>
  </channel>
</rss>

