<?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: Holt-Winters Forecasting in DAX in Quick Measures Gallery</title>
    <link>https://community.fabric.microsoft.com/t5/Quick-Measures-Gallery/Holt-Winters-Forecasting-in-DAX/m-p/3194090#M971</link>
    <description>&lt;P&gt;I don't think people truly appreciate how much skill this actually took to figure out. Having created this measure measures like this myself, I just have to say I respect the work and admire the skill! My video would have involved A LOT more cussing lol&lt;/P&gt;</description>
    <pubDate>Tue, 18 Apr 2023 16:09:24 GMT</pubDate>
    <dc:creator>DataSmiths</dc:creator>
    <dc:date>2023-04-18T16:09:24Z</dc:date>
    <item>
      <title>Holt-Winters Forecasting in DAX</title>
      <link>https://community.fabric.microsoft.com/t5/Quick-Measures-Gallery/Holt-Winters-Forecasting-in-DAX/m-p/2987254#M937</link>
      <description>&lt;P&gt;No, you most certainly should not be doing this. But, I figured, what the heck. Some of the code is provided below. There is lots more code, well over 3,000+ lines. This solution is based on this article by Gregory Trubetskoy:&amp;nbsp;&lt;A href="https://grisha.org/blog/2016/02/17/triple-exponential-smoothing-forecasting-part-iii/" target="_blank" rel="noopener"&gt;Holt-Winters Forecasting for Dummies - Part III - Gregory Trubetskoy (grisha.org)&lt;/A&gt;. I also included the 6 line R solution created by Brian Julius:&amp;nbsp;&lt;A href="https://www.linkedin.com/feed/update/urn:li:activity:7012092785247854592/" target="_blank" rel="noopener"&gt;Post | Feed | LinkedIn&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Here is the video that explains the code.&lt;/P&gt;
&lt;P&gt;&lt;div data-video-id="https://youtu.be/ljwbWm-mdoU" data-video-remote-vid="https://youtu.be/ljwbWm-mdoU" class="lia-video-container lia-media-is-center lia-media-size-medium"&gt;&lt;iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FljwbWm-mdoU%3Ffeature%3Doembed&amp;amp;display_name=YouTube&amp;amp;url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DljwbWm-mdoU&amp;amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2FljwbWm-mdoU%2Fhqdefault.jpg&amp;amp;type=text%2Fhtml&amp;amp;schema=youtube" allowfullscreen="" style="max-width: 100%"&gt;&lt;/iframe&gt;&lt;/div&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Here is some of the code:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;initial_trend = 
    VAR __slen = 12
    VAR __table = 
        ADDCOLUMNS(
            GENERATESERIES(0, __slen - 1, 1),
            "__sum", 
                DIVIDE(
                    MAXX(FILTER('Series', [Index] = [Value] + __slen), [Column]) - 
                        MAXX(FILTER('Series', [Index] = [Value]),[Column]),
                    __slen
                )
        )
    VAR __result = DIVIDE(SUMX(__table, [__sum]), __slen)
RETURN
    __result


Prediction = 
    VAR __slen = 12
    VAR __i = MAX('Indices'[Index])
    VAR __count = COUNTROWS(ALL('Series'))
    VAR __result = 
        IF(
            __i &amp;gt; __count - 1,
                VAR __m = __i - __count + 1
                VAR __smooth = MAX('Forecast71'[smooth])
                VAR __trend = MAX('Forecast71'[trend])
                VAR __mod = MOD(__i, __slen)
                VAR __seasonal = MAXX(FILTER('Seasonal71', [Value] = __mod), [__Value])
                VAR __result = (__smooth + __m * __trend) + __seasonal
            RETURN
                __result,
            BLANK()
        )
RETURN
    __result&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN class="reportid hidden"&gt;eyJrIjoiODBlMGNhMzctZjE2My00MTY4LWEzZGEtOTc5OWQ5OGY2MGY0IiwidCI6IjRhMDQyNzQzLTM3M2EtNDNkMi04MjdiLTAwM2Y0YzdiYTFlNSIsImMiOjN9&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 23 Dec 2022 22:42:47 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Quick-Measures-Gallery/Holt-Winters-Forecasting-in-DAX/m-p/2987254#M937</guid>
      <dc:creator>Greg_Deckler</dc:creator>
      <dc:date>2022-12-23T22:42:47Z</dc:date>
    </item>
    <item>
      <title>Re: Holt-Winters Forecasting in DAX</title>
      <link>https://community.fabric.microsoft.com/t5/Quick-Measures-Gallery/Holt-Winters-Forecasting-in-DAX/m-p/3194090#M971</link>
      <description>&lt;P&gt;I don't think people truly appreciate how much skill this actually took to figure out. Having created this measure measures like this myself, I just have to say I respect the work and admire the skill! My video would have involved A LOT more cussing lol&lt;/P&gt;</description>
      <pubDate>Tue, 18 Apr 2023 16:09:24 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Quick-Measures-Gallery/Holt-Winters-Forecasting-in-DAX/m-p/3194090#M971</guid>
      <dc:creator>DataSmiths</dc:creator>
      <dc:date>2023-04-18T16:09:24Z</dc:date>
    </item>
  </channel>
</rss>

