<?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: DAX Calculation based on Previous Row in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-Calculation-based-on-Previous-Row/m-p/2881160#M93271</link>
    <description>&lt;P&gt;Hi&amp;nbsp;Anonymous&lt;/LI-USER&gt;&amp;nbsp;&lt;BR /&gt;Please refer to attached sample file with the solution&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;LI-CODE lang="javascript"&gt;Step 2 = 
VAR CurrentIndex = 'Table'[Index]
VAR TableBefore = FILTER ( 'Table', 'Table'[Index] &amp;lt; CurrentIndex )
VAR P1 = COUNTROWS ( TableBefore ) + 1
RETURN
    SUMX ( 
        TableBefore,
        VAR X = 'Table'[Step 1]
        VAR P = P1 - 'Table'[Index]
        RETURN
            ( 0.5 ) ^ P * x
    )&lt;/LI-CODE&gt;&lt;LI-CODE lang="markup"&gt;Step 3 = 'Table'[Step 1] + 'Table'[Step 2]&lt;/LI-CODE&gt;</description>
    <pubDate>Wed, 02 Nov 2022 19:36:35 GMT</pubDate>
    <dc:creator>tamerj1</dc:creator>
    <dc:date>2022-11-02T19:36:35Z</dc:date>
    <item>
      <title>DAX Calculation based on Previous Row</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-Calculation-based-on-Previous-Row/m-p/2880462#M93215</link>
      <description>&lt;P&gt;I have a dataset of columns (Index &amp;amp; Step 1)&lt;/P&gt;&lt;P&gt;I am trying to achieve the below calculations for Step 2 and Final&lt;/P&gt;&lt;P&gt;Any suggestions? Thanks&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 02 Nov 2022 14:25:14 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-Calculation-based-on-Previous-Row/m-p/2880462#M93215</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2022-11-02T14:25:14Z</dc:date>
    </item>
    <item>
      <title>Re: DAX Calculation based on Previous Row</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-Calculation-based-on-Previous-Row/m-p/2881160#M93271</link>
      <description>&lt;P&gt;Hi&amp;nbsp;Anonymous&lt;/LI-USER&gt;&amp;nbsp;&lt;BR /&gt;Please refer to attached sample file with the solution&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;LI-CODE lang="javascript"&gt;Step 2 = 
VAR CurrentIndex = 'Table'[Index]
VAR TableBefore = FILTER ( 'Table', 'Table'[Index] &amp;lt; CurrentIndex )
VAR P1 = COUNTROWS ( TableBefore ) + 1
RETURN
    SUMX ( 
        TableBefore,
        VAR X = 'Table'[Step 1]
        VAR P = P1 - 'Table'[Index]
        RETURN
            ( 0.5 ) ^ P * x
    )&lt;/LI-CODE&gt;&lt;LI-CODE lang="markup"&gt;Step 3 = 'Table'[Step 1] + 'Table'[Step 2]&lt;/LI-CODE&gt;</description>
      <pubDate>Wed, 02 Nov 2022 19:36:35 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-Calculation-based-on-Previous-Row/m-p/2881160#M93271</guid>
      <dc:creator>tamerj1</dc:creator>
      <dc:date>2022-11-02T19:36:35Z</dc:date>
    </item>
    <item>
      <title>Re: DAX Calculation based on Previous Row</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-Calculation-based-on-Previous-Row/m-p/2882902#M93367</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="317289" data-lia-user-login="tamerj1" class="lia-mention lia-mention-user"&gt;tamerj1&lt;/a&gt;&amp;nbsp;Thank you! This works like magic! thanks alot &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 03 Nov 2022 12:56:00 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-Calculation-based-on-Previous-Row/m-p/2882902#M93367</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2022-11-03T12:56:00Z</dc:date>
    </item>
    <item>
      <title>Re: DAX Calculation based on Previous Row</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-Calculation-based-on-Previous-Row/m-p/2882907#M93368</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="317289" data-lia-user-login="tamerj1" class="lia-mention lia-mention-user"&gt;tamerj1&lt;/a&gt;&amp;nbsp;I attempted to replace the index row value from the matrix to Month-Year column (Sept 2022, Oct 2022, ...) - Now the numbers are not accurate, does this only work with index?&lt;/P&gt;</description>
      <pubDate>Thu, 03 Nov 2022 12:59:09 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-Calculation-based-on-Previous-Row/m-p/2882907#M93368</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2022-11-03T12:59:09Z</dc:date>
    </item>
    <item>
      <title>Re: DAX Calculation based on Previous Row</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-Calculation-based-on-Previous-Row/m-p/2883196#M93393</link>
      <description>&lt;P&gt;Anonymous&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;It has to be of integer data or date (unique date) type.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 03 Nov 2022 14:44:19 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-Calculation-based-on-Previous-Row/m-p/2883196#M93393</guid>
      <dc:creator>tamerj1</dc:creator>
      <dc:date>2022-11-03T14:44:19Z</dc:date>
    </item>
  </channel>
</rss>

