You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by jb...@apache.org on 2019/08/20 20:55:53 UTC

[lucene-solr] branch SOLR-13105-visual updated: SOLR-13105: Continued timeseries viz docs4

This is an automated email from the ASF dual-hosted git repository.

jbernste pushed a commit to branch SOLR-13105-visual
in repository https://gitbox.apache.org/repos/asf/lucene-solr.git


The following commit(s) were added to refs/heads/SOLR-13105-visual by this push:
     new 4c10a55  SOLR-13105: Continued timeseries viz docs4
4c10a55 is described below

commit 4c10a55261d6fd4b0aeae57a9e6f155fac046cb8
Author: Joel Bernstein <jb...@apache.org>
AuthorDate: Tue Aug 20 16:55:30 2019 -0400

    SOLR-13105: Continued timeseries viz docs4
---
 solr/solr-ref-guide/src/time-series.adoc | 26 +++++++++++++++++++-------
 1 file changed, 19 insertions(+), 7 deletions(-)

diff --git a/solr/solr-ref-guide/src/time-series.adoc b/solr/solr-ref-guide/src/time-series.adoc
index 7764c75..faf26bf 100644
--- a/solr/solr-ref-guide/src/time-series.adoc
+++ b/solr/solr-ref-guide/src/time-series.adoc
@@ -148,9 +148,8 @@ image::images/math-expressions/movingMedian.png[]
 
 == Differencing
 
-Differencing is often used to remove the
-trend or seasonality from a time series. This is known as making a time series
-*stationary*.
+Differencing can be used to make
+a time series stationary by removing the trend or seasonality from data.
 
 === First Difference
 
@@ -159,18 +158,31 @@ original values. The *first difference* takes the difference between a value and
 that came directly before it. The first difference is often used to remove the trend
 from a time series.
 
-In the example below, the `diff` function computes the first difference of a time series.
-The result array length is one value smaller then the original array.
-This is because the `diff` function only returns a result for values
-where the prior value has been subtracted.
+The examples below use the first difference to make two time series stationary so they can be compared
+without the trend.
 
+In this example we'll be comparing the average monthly closing price for two stocks: Amazon and Google.
+The image below plots both time series before differencing is applied.
 
 image::images/math-expressions/timecompare.png[]
 
+In the next example the `diff` function is applied to both time series inside the `zplot` function.
+The `diff` can be applied inside the `zplot` function or like any other function inside of the `let`
+function.
+
+Notice that both time series now have the trend removed and the monthly movements of the stock price
+can be studied without being influenced by the trend.
+
 image::images/math-expressions/diff1.png[]
 
+In the next example the `zoom` function of the time series visualization is used to zoom into a specific
+range of months. This allows for closer inspection of the data. With closer inspection of the data there appears
+to be some correlation between the monthly movements of the two stocks.
+
 image::images/math-expressions/diffzoom.png[]
 
+In the final example the differenced time series are correlated with the `corr` function.
+
 image::images/math-expressions/diffcorr.png[]