<?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: Forecast Time series in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Forecast-Time-series/m-p/459773#M168157</link>
    <description>&lt;P&gt;Why are you pulling boundaries from a lookup table? Why not calculate it dynamically or push it into a summary index? Your current method must be pretty slow &lt;/P&gt;

&lt;P&gt;This wouldn't really qualify as machine learning as your not dynamically populating boundaries based on previous trends. You should let the machine do the work and calculate the boundaries based off historical values rather than storing them in a lookup table. You're going to get lots of Type I and Type II errors with this method&lt;/P&gt;</description>
    <pubDate>Wed, 25 Jul 2018 17:01:33 GMT</pubDate>
    <dc:creator>skoelpin</dc:creator>
    <dc:date>2018-07-25T17:01:33Z</dc:date>
    <item>
      <title>Forecast Time series</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Forecast-Time-series/m-p/459772#M168156</link>
      <description>&lt;P&gt;Hi Ninjas,&lt;/P&gt;

&lt;P&gt;I have a query that looks like this: &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;sourcetype="x" index=y source="z" host="S" 
| bin _time span=10m
| stats dc(CN) as Actual by _time | lookup CN_Forecast_S.csv _time OUTPUT lowerBound pred upperBound 
| eval isOutlierLow=if(Actual &amp;lt; lowerBound , abs(Actual-lowerBound)/lowerBound, 0) 
| eval isOutlierHigh=if(Actual &amp;gt; upperBound, abs(Actual-upperBound)/upperBound, 0)  
| eval isOutlier=if(Actual &amp;lt; lowerBound OR Actual &amp;gt; upperBound, abs(Actual)/abs(upperBound-lowerBound), 0) 
| fields _time, Actual, lowerBound, pred, upperBound, isOutlier, isOutlierLow, isOutlierHigh
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;The &lt;STRONG&gt;CN_Forecast_S.csv&lt;/STRONG&gt; is a lookup file generated by a savedsearch that predict +2days of data. &lt;BR /&gt;
The problem is my query display data until "now" only and I would like to show data for the rest +xdays that I already  have predicted in the same graph. I tried to specify &lt;CODE&gt;lastest=+2d@d&lt;/CODE&gt; , but that didn't work&lt;BR /&gt;
That's the result of my query &lt;BR /&gt;
&lt;IMG src="https://community.splunk.com/storage/temp/253575-predict.png" alt="alt text" /&gt;&lt;BR /&gt;
Thank you in advance.&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 20:38:42 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Forecast-Time-series/m-p/459772#M168156</guid>
      <dc:creator>BenImen</dc:creator>
      <dc:date>2020-09-29T20:38:42Z</dc:date>
    </item>
    <item>
      <title>Re: Forecast Time series</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Forecast-Time-series/m-p/459773#M168157</link>
      <description>&lt;P&gt;Why are you pulling boundaries from a lookup table? Why not calculate it dynamically or push it into a summary index? Your current method must be pretty slow &lt;/P&gt;

&lt;P&gt;This wouldn't really qualify as machine learning as your not dynamically populating boundaries based on previous trends. You should let the machine do the work and calculate the boundaries based off historical values rather than storing them in a lookup table. You're going to get lots of Type I and Type II errors with this method&lt;/P&gt;</description>
      <pubDate>Wed, 25 Jul 2018 17:01:33 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Forecast-Time-series/m-p/459773#M168157</guid>
      <dc:creator>skoelpin</dc:creator>
      <dc:date>2018-07-25T17:01:33Z</dc:date>
    </item>
    <item>
      <title>Re: Forecast Time series</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Forecast-Time-series/m-p/459774#M168158</link>
      <description>&lt;P&gt;I'm populating boundaries dynamically based on previous trends and I'm putting them into a local file via  &lt;EM&gt;outputlookup&lt;/EM&gt; (because I don't have the permission to use the &lt;EM&gt;Collect&lt;/EM&gt; command so I can't store the data into a summary index).&lt;BR /&gt;
The question is how to continue to display the boundaries in the same chart from "now" to +2days. Thank you &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 26 Jul 2018 08:06:32 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Forecast-Time-series/m-p/459774#M168158</guid>
      <dc:creator>BenImen</dc:creator>
      <dc:date>2018-07-26T08:06:32Z</dc:date>
    </item>
    <item>
      <title>Re: Forecast Time series</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Forecast-Time-series/m-p/459775#M168159</link>
      <description>&lt;P&gt;This is not an ideal way, you should either get access to the &lt;CODE&gt;collect&lt;/CODE&gt; command or enable scheudled reports to populate the summary index. &lt;/P&gt;

&lt;P&gt;If you want to push the boundaries into the future, you should use the timeshift technique &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| eval w=case( (_time&amp;gt;relative_time(now(), "+1d@d-5w-30m") AND _time&amp;lt;=relative_time(now(), "+1d@d-5w+1d+30m")), 5, (_time&amp;gt;relative_time(now(), "+1d@d-4w-30m") AND _time&amp;lt;=relative_time(now(), "+1d@d-4w+1d+30m")), 4, (_time&amp;gt;relative_time(now(), "+1d@d-3w-30m") AND _time&amp;lt;=relative_time(now(), "+1d@d-3w+1d+30m")), 3, (_time&amp;gt;relative_time(now(), "+1d@d-2w-30m") AND _time&amp;lt;=relative_time(now(), "+1d@d-2w+1d+30m")), 2, (_time&amp;gt;relative_time(now(), "+1d@d-1w-30m") AND _time&amp;lt;=relative_time(now(), "+1d@d-1w+1d+30m")), 1) 
| eval shift=case(isnotnull(w),"+"+w+"w-30m,+"+w+"w-20m,+"+w+"w-10m,+"+w+"w-0m,+"+w+"w+10m,+"+w+"w+20m,+"+w+"w+30m,") 
| where isnotnull(shift) 
| makemv delim="," shift 
| mvexpand shift 
| eval time=relative_time(_time,shift) 
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 26 Jul 2018 14:16:44 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Forecast-Time-series/m-p/459775#M168159</guid>
      <dc:creator>skoelpin</dc:creator>
      <dc:date>2018-07-26T14:16:44Z</dc:date>
    </item>
    <item>
      <title>Re: Forecast Time series</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Forecast-Time-series/m-p/459776#M168160</link>
      <description>&lt;P&gt;Yes I already doing this:&lt;BR /&gt;
&lt;EM&gt;sourcetype="X" index=Y source="Z" host="S" &lt;BR /&gt;
| bin _time span=10m&lt;BR /&gt;
| stats dc(CN) as Actual by host, _time&lt;BR /&gt;
| &lt;CODE&gt;Forecast4w(Actual,90.0,+1d,1)&lt;/CODE&gt; | outputlookup CN_Forecast_S.csv append=True&lt;/EM&gt;&lt;BR /&gt;
The &lt;STRONG&gt;Forcast4w&lt;/STRONG&gt; is a macro that contain the timeshift technique, and I scheduled this to run every day&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 20:39:32 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Forecast-Time-series/m-p/459776#M168160</guid>
      <dc:creator>BenImen</dc:creator>
      <dc:date>2020-09-29T20:39:32Z</dc:date>
    </item>
    <item>
      <title>Re: Forecast Time series</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Forecast-Time-series/m-p/459777#M168161</link>
      <description>&lt;P&gt;So you should be pushing it 1 day into the future already then.. &lt;/P&gt;</description>
      <pubDate>Thu, 26 Jul 2018 15:54:51 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Forecast-Time-series/m-p/459777#M168161</guid>
      <dc:creator>skoelpin</dc:creator>
      <dc:date>2018-07-26T15:54:51Z</dc:date>
    </item>
    <item>
      <title>Re: Forecast Time series</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Forecast-Time-series/m-p/459778#M168162</link>
      <description>&lt;P&gt;It's a display issue: my current query show the "pred" just until now and I would like that continue to display the rest of the data generated by the Forcast4w macro. I didn't get the result desired by  specifying the Latest time &lt;A href="mailto:+1d@d"&gt;+1d@d&lt;/A&gt;. Sorry if i wasn't clear enough!&lt;/P&gt;</description>
      <pubDate>Tue, 31 Jul 2018 10:13:08 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Forecast-Time-series/m-p/459778#M168162</guid>
      <dc:creator>BenImen</dc:creator>
      <dc:date>2018-07-31T10:13:08Z</dc:date>
    </item>
    <item>
      <title>Re: Forecast Time series</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Forecast-Time-series/m-p/459779#M168163</link>
      <description>&lt;P&gt;So your issue is solved then? Can you accept the answer to close out the question?&lt;/P&gt;</description>
      <pubDate>Tue, 31 Jul 2018 13:48:32 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Forecast-Time-series/m-p/459779#M168163</guid>
      <dc:creator>skoelpin</dc:creator>
      <dc:date>2018-07-31T13:48:32Z</dc:date>
    </item>
    <item>
      <title>Re: Forecast Time series</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Forecast-Time-series/m-p/459780#M168164</link>
      <description>&lt;P&gt;Not yet, still have this issue!&lt;/P&gt;</description>
      <pubDate>Tue, 31 Jul 2018 14:07:40 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Forecast-Time-series/m-p/459780#M168164</guid>
      <dc:creator>BenImen</dc:creator>
      <dc:date>2018-07-31T14:07:40Z</dc:date>
    </item>
    <item>
      <title>Re: Forecast Time series</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Forecast-Time-series/m-p/459781#M168165</link>
      <description>&lt;P&gt;I'm not clear on your problem. What is not working properly? &lt;/P&gt;</description>
      <pubDate>Tue, 31 Jul 2018 14:14:45 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Forecast-Time-series/m-p/459781#M168165</guid>
      <dc:creator>skoelpin</dc:creator>
      <dc:date>2018-07-31T14:14:45Z</dc:date>
    </item>
  </channel>
</rss>

