<?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 sort columns and delete repeated rows in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/How-to-sort-columns-and-delete-repeated-rows/m-p/16592#M15117</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If you use the Lag() function you will not get an error.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;lat(ENTITY&lt;I&gt;) will point to the save column(row) as ENTITY[i-1]&lt;/I&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 01 Feb 2016 21:47:10 GMT</pubDate>
    <dc:creator>txnelson</dc:creator>
    <dc:date>2016-02-01T21:47:10Z</dc:date>
    <item>
      <title>How to sort columns and delete repeated rows</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-sort-columns-and-delete-repeated-rows/m-p/16588#M15113</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;New to scripting in JMP and want to filter the table of tool errors. I have a set of data and want to filter by alarm date next delete the repeated rows of errors. For example, if an error occurs at 1:00 and it repeats itself 4 times within 1 hour I want to delete the repeats and only catches when the error first appears. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My script is below and I want to resort the script after I do the delete of repeated rows by alarm date (descending).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;dt = open ("SR_Loop_LAM_002_Alarm_Log.csv");&lt;/P&gt;&lt;P&gt;dt &amp;lt;&amp;lt; sort (by (:ENTITY), order (ascending), replace table (0));&lt;/P&gt;&lt;P&gt;for (i = nrows (dt), i&amp;gt;0, i--, &lt;/P&gt;&lt;P&gt;&amp;nbsp; if(:ENTITY[i-1]==:ENTITY&lt;I&gt; &amp;amp; :ALARM_ID[i-1] == :ALARM_ID &lt;I&gt; &amp;amp; date difference(:ALARM_DATE[i-1], :ALARM_DATE&lt;I&gt;, "hour", "fractional") &amp;lt; 1,&lt;/I&gt;&lt;/I&gt;&lt;/I&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; dt &amp;lt;&amp;lt; delete rows (i))&lt;/P&gt;&lt;P&gt;);&lt;/P&gt;&lt;P&gt;dt &amp;lt;&amp;lt; save ("SR_Loop_LAM_002_Alarm_Log.csv");&lt;/P&gt;&lt;P&gt;close (dt, no save)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 01 Feb 2016 17:11:35 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-sort-columns-and-delete-repeated-rows/m-p/16588#M15113</guid>
      <dc:creator>evanchen870</dc:creator>
      <dc:date>2016-02-01T17:11:35Z</dc:date>
    </item>
    <item>
      <title>Re: How to sort columns and delete repeated rows</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-sort-columns-and-delete-repeated-rows/m-p/16589#M15114</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;current JMP error is "Invalid row number in access or evaluation of 'subscript', "ENTITY[i-1]"&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 01 Feb 2016 17:20:43 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-sort-columns-and-delete-repeated-rows/m-p/16589#M15114</guid>
      <dc:creator>evanchen870</dc:creator>
      <dc:date>2016-02-01T17:20:43Z</dc:date>
    </item>
    <item>
      <title>Re: How to sort columns and delete repeated rows</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-sort-columns-and-delete-repeated-rows/m-p/16590#M15115</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Looks like you are nearly there. Your 'for' loop terminates at the value of i=1, but you are indexing i-1=0. JMP subscripts always start from 1. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 01 Feb 2016 17:38:39 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-sort-columns-and-delete-repeated-rows/m-p/16590#M15115</guid>
      <dc:creator>ian_jmp</dc:creator>
      <dc:date>2016-02-01T17:38:39Z</dc:date>
    </item>
    <item>
      <title>Re: How to sort columns and delete repeated rows</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-sort-columns-and-delete-repeated-rows/m-p/16591#M15116</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks for the quick response Ian, but the script is still not doing what I want it to do.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Currently, I have columns ENTITY, ALARM_DATE, ENTITY_TYPE, ALARM_ID, and ALARM_DESCRIPTION&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1. I first want my script to sort by either ENTITY, ALARM_DATE, or ENTITY_TYPE&lt;/P&gt;&lt;P&gt;2. then I want to use a if loop to delete repeated alarms (by ALARM_DESCRIPTION) within 1 hr of time difference of the ALARM_DATE&lt;/P&gt;&lt;P&gt;3. lastly I want to sort by ALARM_DATE (descending) to replace the original table&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So, by your suggestions I will need to change to&amp;nbsp; &lt;SPAN style="color: #555555; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;(i = nrows (dt), i&amp;gt;1, i--)?&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 01 Feb 2016 18:09:52 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-sort-columns-and-delete-repeated-rows/m-p/16591#M15116</guid>
      <dc:creator>evanchen870</dc:creator>
      <dc:date>2016-02-01T18:09:52Z</dc:date>
    </item>
    <item>
      <title>Re: How to sort columns and delete repeated rows</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-sort-columns-and-delete-repeated-rows/m-p/16592#M15117</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If you use the Lag() function you will not get an error.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;lat(ENTITY&lt;I&gt;) will point to the save column(row) as ENTITY[i-1]&lt;/I&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 01 Feb 2016 21:47:10 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-sort-columns-and-delete-repeated-rows/m-p/16592#M15117</guid>
      <dc:creator>txnelson</dc:creator>
      <dc:date>2016-02-01T21:47:10Z</dc:date>
    </item>
    <item>
      <title>Re: How to sort columns and delete repeated rows</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-sort-columns-and-delete-repeated-rows/m-p/16593#M15118</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi &lt;A href="https://kvoqx44227.lithium.com/people/evanchen870" target="_blank"&gt;evanchen870&lt;/A&gt;​&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;take a look at this discussion from the past the script is also very fast and robust for deleting since it uses "get rows where"&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.jmp.com/message/224030" target="_blank"&gt;Re: Stop a loop&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;good luck!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 28 Oct 2016 13:23:50 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-sort-columns-and-delete-repeated-rows/m-p/16593#M15118</guid>
      <dc:creator>ron_horne</dc:creator>
      <dc:date>2016-10-28T13:23:50Z</dc:date>
    </item>
    <item>
      <title>Re: How to sort columns and delete repeated rows</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-sort-columns-and-delete-repeated-rows/m-p/16594#M15119</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Evan,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There are a number of ways you could go around it.&amp;nbsp; There is a specific challenge with your duplicate removal in that you want to remove 'duplicates' that occur within an hour of the same alarm.&amp;nbsp; This requires lag function logic, which in turn requires the data be appropriately ordered before execution.&amp;nbsp; Furthermore if you delete a row before execution of the next logic then you could end up with out of bounds errors in looping.&amp;nbsp; One workaround is to set a flag for duplicate removal, this can be done by creating a boolean column or by using some built in features.&amp;nbsp; Below I've modified your code to use row selection as that flag.&amp;nbsp; After the logic is performed to determine if the alarm is a duplicate, all rows are deleted at once.&amp;nbsp; Further speed is added by opening the table in invisible mode so that screen I/O is avoided.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #008000; font-family: Courier; font-size: 13.3333px;"&gt;/* data table made invisible to speed up execution */&lt;/SPAN&gt;&lt;SPAN style="color: #000000; font-family: Courier; font-size: 13.3333px;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P class="MsoNormal" style="mso-pagination: none; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt;dt &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: #0000dd;"&gt;Open&lt;/SPAN&gt;&lt;STRONG style="mso-bidi-font-family: Courier; color: black; font-family: Courier;"&gt;(&lt;/STRONG&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: purple;"&gt;"SR_Loop_LAM_002_Alarm_Log.csv"&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; , invisible &lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="MsoNormal" style="mso-pagination: none; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="MsoNormal" style="mso-pagination: none; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt;&lt;SPAN style="color: #008000; font-family: Courier; font-size: 13.3333px;"&gt;/* updated for multiple sort */&lt;/SPAN&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P class="MsoNormal" style="mso-pagination: none; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt;dt &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;&amp;lt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; &lt;/SPAN&gt;&lt;STRONG style="mso-bidi-font-family: Courier; color: navy; font-family: Courier;"&gt;Sort&lt;/STRONG&gt;&lt;STRONG style="mso-bidi-font-family: Courier; color: black; font-family: Courier;"&gt;(&lt;/STRONG&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; By&lt;STRONG&gt;(&lt;/STRONG&gt; &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;:&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt;ENTITY&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;:&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt;ALARM_DATE &lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; Order&lt;STRONG&gt;(&lt;/STRONG&gt; Ascending&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; Ascending &lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; Replace Table&lt;STRONG&gt;(&lt;/STRONG&gt; &lt;/SPAN&gt;&lt;STRONG style="mso-bidi-font-family: Courier; color: teal; font-family: Courier;"&gt;0&lt;/STRONG&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; &lt;STRONG&gt;)&lt;/STRONG&gt; &lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="MsoNormal" style="mso-pagination: none; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P class="MsoNormal" style="mso-pagination: none; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: green;"&gt;/* clear row and column selection first (just good coding habit) */&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="MsoNormal" style="mso-pagination: none; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt;dt &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;&amp;lt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; &lt;/SPAN&gt;&lt;STRONG style="mso-bidi-font-family: Courier; color: navy; font-family: Courier;"&gt;Clear Select&lt;/STRONG&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="MsoNormal" style="mso-pagination: none; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt;dt &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;&amp;lt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; &lt;/SPAN&gt;&lt;STRONG style="mso-bidi-font-family: Courier; color: navy; font-family: Courier;"&gt;Clear Column Selection&lt;/STRONG&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="MsoNormal" style="mso-pagination: none; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="MsoNormal" style="mso-pagination: none; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: green;"&gt;/* select rows that meet the specified conditions&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="MsoNormal" style="mso-pagination: none; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: green;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; because this is going from bottom to top the loop should stop at row 1 (there is no row 0)&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="MsoNormal" style="mso-pagination: none; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: green;"&gt;*/&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="MsoNormal" style="mso-pagination: none; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: #0000dd;"&gt;For&lt;/SPAN&gt;&lt;STRONG style="mso-bidi-font-family: Courier; color: black; font-family: Courier;"&gt;(&lt;/STRONG&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; i &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: #0000dd;"&gt;N Rows&lt;/SPAN&gt;&lt;STRONG style="mso-bidi-font-family: Courier; color: black; font-family: Courier;"&gt;(&lt;/STRONG&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; dt &lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; i &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #008080; font-family: Courier;"&gt;&lt;STRONG&gt;1&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; i&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;--,&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="MsoNormal" style="mso-pagination: none; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;SPAN style="mso-tab-count: 1; mso-bidi-font-family: Courier; color: black; font-family: Courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: #0000dd;"&gt;If&lt;/SPAN&gt;&lt;STRONG style="mso-bidi-font-family: Courier; color: black; font-family: Courier;"&gt;(&lt;/STRONG&gt;&lt;/P&gt;&lt;P class="MsoNormal" style="mso-pagination: none; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;SPAN style="mso-tab-count: 2; mso-bidi-font-family: Courier; color: black; font-family: Courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;:&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt;ENTITY&lt;STRONG&gt;[&lt;/STRONG&gt;i &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;-&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; &lt;/SPAN&gt;&lt;STRONG style="mso-bidi-font-family: Courier; color: teal; font-family: Courier;"&gt;1&lt;/STRONG&gt;&lt;STRONG style="mso-bidi-font-family: Courier; color: black; font-family: Courier;"&gt;]&lt;/STRONG&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;==&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;:&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt;ENTITY&lt;STRONG&gt;[&lt;/STRONG&gt;i&lt;STRONG&gt;]&lt;/STRONG&gt; &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;&amp;amp;&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P class="MsoNormal" style="mso-pagination: none; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;SPAN style="mso-tab-count: 2; mso-bidi-font-family: Courier; color: black; font-family: Courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;:&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt;ALARM_ID&lt;STRONG&gt;[&lt;/STRONG&gt;i &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;-&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; &lt;/SPAN&gt;&lt;STRONG style="mso-bidi-font-family: Courier; color: teal; font-family: Courier;"&gt;1&lt;/STRONG&gt;&lt;STRONG style="mso-bidi-font-family: Courier; color: black; font-family: Courier;"&gt;]&lt;/STRONG&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;==&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;:&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt;ALARM_ID&lt;STRONG&gt;[&lt;/STRONG&gt;i&lt;STRONG&gt;]&lt;/STRONG&gt; &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;&amp;amp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="MsoNormal" style="mso-pagination: none; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;SPAN style="mso-tab-count: 2; mso-bidi-font-family: Courier; color: black; font-family: Courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: #0000dd;"&gt;Date Difference&lt;/SPAN&gt;&lt;STRONG style="mso-bidi-font-family: Courier; color: black; font-family: Courier;"&gt;(&lt;/STRONG&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;:&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt;ALARM_DATE&lt;STRONG&gt;[&lt;/STRONG&gt;i &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;-&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; &lt;/SPAN&gt;&lt;STRONG style="mso-bidi-font-family: Courier; color: teal; font-family: Courier;"&gt;1&lt;/STRONG&gt;&lt;STRONG style="mso-bidi-font-family: Courier; color: black; font-family: Courier;"&gt;]&lt;/STRONG&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;:&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt;ALARM_DATE&lt;STRONG&gt;[&lt;/STRONG&gt;i&lt;STRONG&gt;]&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: purple;"&gt;"hour"&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: purple;"&gt;"fractional"&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; &lt;STRONG&gt;)&lt;/STRONG&gt; &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; &lt;/SPAN&gt;&lt;STRONG style="mso-bidi-font-family: Courier; color: teal; font-family: Courier;"&gt;1&lt;/STRONG&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;,&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="MsoNormal" style="mso-pagination: none; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt;&lt;SPAN style="mso-tab-count: 2;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;dt &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;&amp;lt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; &lt;/SPAN&gt;&lt;STRONG style="mso-bidi-font-family: Courier; color: navy; font-family: Courier;"&gt;Select Rows&lt;/STRONG&gt;&lt;STRONG style="mso-bidi-font-family: Courier; color: black; font-family: Courier;"&gt;(&lt;/STRONG&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; i &lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="MsoNormal" style="mso-pagination: none; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt;&lt;SPAN style="mso-tab-count: 1;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="MsoNormal" style="mso-pagination: none; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;STRONG style="mso-bidi-font-family: Courier; color: black; font-family: Courier;"&gt;)&lt;/STRONG&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="MsoNormal" style="mso-pagination: none; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: green;"&gt;/* delete the selected rows */&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="MsoNormal" style="mso-pagination: none; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt;dt &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;&amp;lt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; &lt;/SPAN&gt;&lt;STRONG style="mso-bidi-font-family: Courier; color: navy; font-family: Courier;"&gt;Delete Rows&lt;/STRONG&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="MsoNormal" style="mso-pagination: none; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-family: Courier; color: black;"&gt;&lt;SPAN style="color: #008000; font-family: Courier; font-size: 13.3333px;"&gt;/* final sort */&lt;/SPAN&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-family: Courier; color: black;"&gt;dt &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; color: navy;"&gt;&amp;lt;&amp;lt;&lt;/SPAN&gt; &lt;STRONG&gt;&lt;SPAN style="font-family: Courier; color: navy;"&gt;Sort&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; color: black;"&gt;(&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;SPAN style="font-family: Courier; color: black;"&gt; By&lt;STRONG&gt;(&lt;/STRONG&gt; \&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; color: navy;"&gt;:&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; color: black;"&gt;ALARM_DATE &lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; color: navy;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; color: black;"&gt; Order&lt;STRONG&gt;(&lt;/STRONG&gt; De&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; color: black;"&gt;scending &lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; color: navy;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; color: black;"&gt; Replace Table&lt;STRONG&gt;(&lt;/STRONG&gt; &lt;/SPAN&gt;&lt;STRONG style="color: teal; font-family: Courier;"&gt;0&lt;/STRONG&gt;&lt;SPAN style="font-family: Courier; color: black;"&gt; &lt;STRONG&gt;)&lt;/STRONG&gt; &lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="MsoNormal" style="mso-pagination: none; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P class="MsoNormal" style="mso-pagination: none; mso-layout-grid-align: none; text-autospace: none;"&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt;dt &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;&amp;lt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; &lt;/SPAN&gt;&lt;STRONG style="mso-bidi-font-family: Courier; color: navy; font-family: Courier;"&gt;save&lt;/STRONG&gt;&lt;STRONG style="mso-bidi-font-family: Courier; color: black; font-family: Courier;"&gt;(&lt;/STRONG&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: purple;"&gt;"SR_Loop_LAM_002_Alarm_Log_cleansed.csv"&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; &lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P class="MsoNormal"&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: #0000dd;"&gt;Close&lt;/SPAN&gt;&lt;STRONG style="mso-bidi-font-family: Courier; color: black; font-family: Courier;"&gt;(&lt;/STRONG&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; dt&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: black;"&gt; no save &lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier; mso-bidi-font-family: Courier; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Feb 2016 19:41:33 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-sort-columns-and-delete-repeated-rows/m-p/16594#M15119</guid>
      <dc:creator>Nate_Riordan</dc:creator>
      <dc:date>2016-02-02T19:41:33Z</dc:date>
    </item>
    <item>
      <title>Re: How to sort columns and delete repeated rows</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-sort-columns-and-delete-repeated-rows/m-p/16595#M15120</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you all for the great response! I have edit my script and it working beautifully now. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 Feb 2016 23:32:58 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-sort-columns-and-delete-repeated-rows/m-p/16595#M15120</guid>
      <dc:creator>evanchen870</dc:creator>
      <dc:date>2016-02-03T23:32:58Z</dc:date>
    </item>
  </channel>
</rss>

