<?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 How to check if Lag(:column, N) points to existing row in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/How-to-check-if-Lag-column-N-points-to-existing-row/m-p/473836#M71861</link>
    <description>&lt;P&gt;Whern I use Lag(function) I usually do not lag more than one row, so I just include a condition for the first row. But what if I have multiple Lags with different amounts of rows to lag? What would be the best way to check if it refers to an existing row, leave as is, if it lags to before the first row - just return 0? I would try something like Is Scriptable(), but it doesn't' work in this case.&lt;/P&gt;</description>
    <pubDate>Fri, 09 Jun 2023 18:14:35 GMT</pubDate>
    <dc:creator>miguello</dc:creator>
    <dc:date>2023-06-09T18:14:35Z</dc:date>
    <item>
      <title>How to check if Lag(:column, N) points to existing row</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-check-if-Lag-column-N-points-to-existing-row/m-p/473836#M71861</link>
      <description>&lt;P&gt;Whern I use Lag(function) I usually do not lag more than one row, so I just include a condition for the first row. But what if I have multiple Lags with different amounts of rows to lag? What would be the best way to check if it refers to an existing row, leave as is, if it lags to before the first row - just return 0? I would try something like Is Scriptable(), but it doesn't' work in this case.&lt;/P&gt;</description>
      <pubDate>Fri, 09 Jun 2023 18:14:35 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-check-if-Lag-column-N-points-to-existing-row/m-p/473836#M71861</guid>
      <dc:creator>miguello</dc:creator>
      <dc:date>2023-06-09T18:14:35Z</dc:date>
    </item>
    <item>
      <title>Re: How to check if Lag(:column, N) points to existing row</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-check-if-Lag-column-N-points-to-existing-row/m-p/473865#M71863</link>
      <description>&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;if(!(Is Missing(Lag(:column, N))), Lag(:column, N), 0)&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 28 Mar 2022 18:01:37 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-check-if-Lag-column-N-points-to-existing-row/m-p/473865#M71863</guid>
      <dc:creator>miguello</dc:creator>
      <dc:date>2022-03-28T18:01:37Z</dc:date>
    </item>
  </channel>
</rss>

