Clustering time series based on monotonic similarityR: Comparing dissimilarity between metabolic models with discrete wavelet transformationClassify Customers based on 2 features AND a Time series of eventsClustering users based on buying behaviourHow to cluster multiple time-series from one data frameAgglomerative Hierarchial Clustering in python using DTW distancehow to compare different sets of time series dataDifference between Time series clustering and Time series SegmentationDoes hierarchical agglomerative clustering with centroid-linkage suffer from chain-effect?Code or Package to cluster sequences (or time series) of different lengths based on HMM?Any cluster algo can cluster time series datasets based on variation ratio(or quantity)?

Why does the Persian emissary display a string of crowned skulls?

Proving an identity involving cross products and coplanar vectors

How do I prevent inappropriate ads from appearing in my game?

Storage of electrolytic capacitors - how long?

If Captain Marvel (MCU) were to have a child with a human male, would the child be human or Kree?

What's the name of the logical fallacy where a debater extends a statement far beyond the original statement to make it true?

Sigmoid with a slope but no asymptotes?

How to make money from a browser who sees 5 seconds into the future of any web page?

What happens if I try to grapple mirror image?

Why can't the Brexit deadlock in the UK parliament be solved with a plurality vote?

Quoting Keynes in a lecture

Determining multivariate least squares with constraint

How do I fix the group tension caused by my character stealing and possibly killing without provocation?

Ways of geometrical multiplication

How do I tell my boss that I'm quitting in 15 days (a colleague left this week)

Review your own paper in Mathematics

How to leave product feedback on macOS?

Animation: customize bounce interpolation

Why the "ls" command is showing the permissions of files in a FAT32 partition?

Possible Eco thriller, man invents a device to remove rain from glass

Should I warn a new PhD Student?

How to make a list of partial sums using forEach

SOQL query causes internal Salesforce error

What is the meaning of "You've never met a graph you didn't like?"



Clustering time series based on monotonic similarity


R: Comparing dissimilarity between metabolic models with discrete wavelet transformationClassify Customers based on 2 features AND a Time series of eventsClustering users based on buying behaviourHow to cluster multiple time-series from one data frameAgglomerative Hierarchial Clustering in python using DTW distancehow to compare different sets of time series dataDifference between Time series clustering and Time series SegmentationDoes hierarchical agglomerative clustering with centroid-linkage suffer from chain-effect?Code or Package to cluster sequences (or time series) of different lengths based on HMM?Any cluster algo can cluster time series datasets based on variation ratio(or quantity)?













2












$begingroup$


Context



I am involved in a task of clustering 1500 time series of 500 observations into a few number of clusters. The time series share all the same observed property at different spatial locations, but responding to the same exogenous variables. However, for each time series, the magnitude of the response is very different. For a time series of reference $X$, I would like to be grouped in the same cluster series that are alike $X^a$ for all $a > 0$.



Tryouts



So far, my interpretation of the problem is that I want to cluster time series sharing a strong monotonic relationship. My first tryouts used hierarchical agglomerative clustering by defining a distance based Kendall's tau rank coefficient since it measures the strength of a monotonic relationship. By visual interpretation, best results were obtained using Ward's linkage method. However, this approach seems unorthodox, non-robust, or doubtful for several reasons.



First, Scipy documentation mentions here that Ward's method is only correct when the Euclidean distance is used. Secondly, I couldn't find any detailed application of time series clustering based either on Spearman or Kendall's tau coefficient. Furthermore, I was very surprised that I couldn't find any paper or reference aiming at clustering based on a monotonic criterion.



I am willing to consider other approaches, though I cannot measure their benefits. For instance, rescaling all time-series to map them to a standardized gaussian distribution (e.g. Box-Cox) and then using the Euclidean distance. Another possibility is to turn the first difference of time series into a boolean vector (1 if $Delta X >0$, $0$ otherwise) and then use the Euclidean distance or another distance metric.



Questions



Since I am new to time series clustering, I have some troubles to picture by myself what would be the best approach(es) (or the worse) for this specific purpose. Hence, I have two related questions:



  1. Specifically, is using Hierarchical Clustering based on Kendall's tau and Ward's linkage method a wrong way to go and why?

  2. Generally, what is the best way to cluster time series based on monotonic association?

Some references on the topic are also welcome.










share|improve this question









$endgroup$




bumped to the homepage by Community 31 mins ago


This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.



















    2












    $begingroup$


    Context



    I am involved in a task of clustering 1500 time series of 500 observations into a few number of clusters. The time series share all the same observed property at different spatial locations, but responding to the same exogenous variables. However, for each time series, the magnitude of the response is very different. For a time series of reference $X$, I would like to be grouped in the same cluster series that are alike $X^a$ for all $a > 0$.



    Tryouts



    So far, my interpretation of the problem is that I want to cluster time series sharing a strong monotonic relationship. My first tryouts used hierarchical agglomerative clustering by defining a distance based Kendall's tau rank coefficient since it measures the strength of a monotonic relationship. By visual interpretation, best results were obtained using Ward's linkage method. However, this approach seems unorthodox, non-robust, or doubtful for several reasons.



    First, Scipy documentation mentions here that Ward's method is only correct when the Euclidean distance is used. Secondly, I couldn't find any detailed application of time series clustering based either on Spearman or Kendall's tau coefficient. Furthermore, I was very surprised that I couldn't find any paper or reference aiming at clustering based on a monotonic criterion.



    I am willing to consider other approaches, though I cannot measure their benefits. For instance, rescaling all time-series to map them to a standardized gaussian distribution (e.g. Box-Cox) and then using the Euclidean distance. Another possibility is to turn the first difference of time series into a boolean vector (1 if $Delta X >0$, $0$ otherwise) and then use the Euclidean distance or another distance metric.



    Questions



    Since I am new to time series clustering, I have some troubles to picture by myself what would be the best approach(es) (or the worse) for this specific purpose. Hence, I have two related questions:



    1. Specifically, is using Hierarchical Clustering based on Kendall's tau and Ward's linkage method a wrong way to go and why?

    2. Generally, what is the best way to cluster time series based on monotonic association?

    Some references on the topic are also welcome.










    share|improve this question









    $endgroup$




    bumped to the homepage by Community 31 mins ago


    This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.

















      2












      2








      2


      1



      $begingroup$


      Context



      I am involved in a task of clustering 1500 time series of 500 observations into a few number of clusters. The time series share all the same observed property at different spatial locations, but responding to the same exogenous variables. However, for each time series, the magnitude of the response is very different. For a time series of reference $X$, I would like to be grouped in the same cluster series that are alike $X^a$ for all $a > 0$.



      Tryouts



      So far, my interpretation of the problem is that I want to cluster time series sharing a strong monotonic relationship. My first tryouts used hierarchical agglomerative clustering by defining a distance based Kendall's tau rank coefficient since it measures the strength of a monotonic relationship. By visual interpretation, best results were obtained using Ward's linkage method. However, this approach seems unorthodox, non-robust, or doubtful for several reasons.



      First, Scipy documentation mentions here that Ward's method is only correct when the Euclidean distance is used. Secondly, I couldn't find any detailed application of time series clustering based either on Spearman or Kendall's tau coefficient. Furthermore, I was very surprised that I couldn't find any paper or reference aiming at clustering based on a monotonic criterion.



      I am willing to consider other approaches, though I cannot measure their benefits. For instance, rescaling all time-series to map them to a standardized gaussian distribution (e.g. Box-Cox) and then using the Euclidean distance. Another possibility is to turn the first difference of time series into a boolean vector (1 if $Delta X >0$, $0$ otherwise) and then use the Euclidean distance or another distance metric.



      Questions



      Since I am new to time series clustering, I have some troubles to picture by myself what would be the best approach(es) (or the worse) for this specific purpose. Hence, I have two related questions:



      1. Specifically, is using Hierarchical Clustering based on Kendall's tau and Ward's linkage method a wrong way to go and why?

      2. Generally, what is the best way to cluster time series based on monotonic association?

      Some references on the topic are also welcome.










      share|improve this question









      $endgroup$




      Context



      I am involved in a task of clustering 1500 time series of 500 observations into a few number of clusters. The time series share all the same observed property at different spatial locations, but responding to the same exogenous variables. However, for each time series, the magnitude of the response is very different. For a time series of reference $X$, I would like to be grouped in the same cluster series that are alike $X^a$ for all $a > 0$.



      Tryouts



      So far, my interpretation of the problem is that I want to cluster time series sharing a strong monotonic relationship. My first tryouts used hierarchical agglomerative clustering by defining a distance based Kendall's tau rank coefficient since it measures the strength of a monotonic relationship. By visual interpretation, best results were obtained using Ward's linkage method. However, this approach seems unorthodox, non-robust, or doubtful for several reasons.



      First, Scipy documentation mentions here that Ward's method is only correct when the Euclidean distance is used. Secondly, I couldn't find any detailed application of time series clustering based either on Spearman or Kendall's tau coefficient. Furthermore, I was very surprised that I couldn't find any paper or reference aiming at clustering based on a monotonic criterion.



      I am willing to consider other approaches, though I cannot measure their benefits. For instance, rescaling all time-series to map them to a standardized gaussian distribution (e.g. Box-Cox) and then using the Euclidean distance. Another possibility is to turn the first difference of time series into a boolean vector (1 if $Delta X >0$, $0$ otherwise) and then use the Euclidean distance or another distance metric.



      Questions



      Since I am new to time series clustering, I have some troubles to picture by myself what would be the best approach(es) (or the worse) for this specific purpose. Hence, I have two related questions:



      1. Specifically, is using Hierarchical Clustering based on Kendall's tau and Ward's linkage method a wrong way to go and why?

      2. Generally, what is the best way to cluster time series based on monotonic association?

      Some references on the topic are also welcome.







      time-series clustering preprocessing distance






      share|improve this question













      share|improve this question











      share|improve this question




      share|improve this question










      asked Feb 13 at 14:33









      DelforgeDelforge

      1114




      1114





      bumped to the homepage by Community 31 mins ago


      This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.







      bumped to the homepage by Community 31 mins ago


      This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.






















          1 Answer
          1






          active

          oldest

          votes


















          0












          $begingroup$

          The way Ward's linkage is computed really only makes sense with squared Euclidean type of measures. Only then the Konig-Huygens theorem can be used.



          Why don't you consider average linkage? Why Ward?






          share|improve this answer









          $endgroup$












          • $begingroup$
            As it is a spatiotemporal dataset, I am able to check how clusters are spatially distributed. Kendall + Average linkage yields to one dominant cluster while the others are small and spatially split. Ward + Kendall yield to more consistent clusters with respect to the spatial structure of the system. However, I am able to get a similar spatial distribution using Pearson's correlation on Z standardized data with Ward linkage. This is even better if I apply a quantile mapping to a normal distribution on my time series. I guess it might be more be "mathematical" than relying on Kendall's tau.
            $endgroup$
            – Delforge
            Feb 19 at 10:26










          • $begingroup$
            Pearson does its own normalization... And it's easy to prove that it is related to Euclidean on appropriately preprocessed data. So if you do this math, you may be able to set it up so that you can use Euclidean (and hence Ward) to get Pearson results. You just need to show that you can pull out the normalization, and that it won't yield a division by 0 on your data.
            $endgroup$
            – Anony-Mousse
            Feb 19 at 11:50










          Your Answer





          StackExchange.ifUsing("editor", function ()
          return StackExchange.using("mathjaxEditing", function ()
          StackExchange.MarkdownEditor.creationCallbacks.add(function (editor, postfix)
          StackExchange.mathjaxEditing.prepareWmdForMathJax(editor, postfix, [["$", "$"], ["\\(","\\)"]]);
          );
          );
          , "mathjax-editing");

          StackExchange.ready(function()
          var channelOptions =
          tags: "".split(" "),
          id: "557"
          ;
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function()
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled)
          StackExchange.using("snippets", function()
          createEditor();
          );

          else
          createEditor();

          );

          function createEditor()
          StackExchange.prepareEditor(
          heartbeatType: 'answer',
          autoActivateHeartbeat: false,
          convertImagesToLinks: false,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: null,
          bindNavPrevention: true,
          postfix: "",
          imageUploader:
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          ,
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          );



          );













          draft saved

          draft discarded


















          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fdatascience.stackexchange.com%2fquestions%2f45510%2fclustering-time-series-based-on-monotonic-similarity%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown

























          1 Answer
          1






          active

          oldest

          votes








          1 Answer
          1






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes









          0












          $begingroup$

          The way Ward's linkage is computed really only makes sense with squared Euclidean type of measures. Only then the Konig-Huygens theorem can be used.



          Why don't you consider average linkage? Why Ward?






          share|improve this answer









          $endgroup$












          • $begingroup$
            As it is a spatiotemporal dataset, I am able to check how clusters are spatially distributed. Kendall + Average linkage yields to one dominant cluster while the others are small and spatially split. Ward + Kendall yield to more consistent clusters with respect to the spatial structure of the system. However, I am able to get a similar spatial distribution using Pearson's correlation on Z standardized data with Ward linkage. This is even better if I apply a quantile mapping to a normal distribution on my time series. I guess it might be more be "mathematical" than relying on Kendall's tau.
            $endgroup$
            – Delforge
            Feb 19 at 10:26










          • $begingroup$
            Pearson does its own normalization... And it's easy to prove that it is related to Euclidean on appropriately preprocessed data. So if you do this math, you may be able to set it up so that you can use Euclidean (and hence Ward) to get Pearson results. You just need to show that you can pull out the normalization, and that it won't yield a division by 0 on your data.
            $endgroup$
            – Anony-Mousse
            Feb 19 at 11:50















          0












          $begingroup$

          The way Ward's linkage is computed really only makes sense with squared Euclidean type of measures. Only then the Konig-Huygens theorem can be used.



          Why don't you consider average linkage? Why Ward?






          share|improve this answer









          $endgroup$












          • $begingroup$
            As it is a spatiotemporal dataset, I am able to check how clusters are spatially distributed. Kendall + Average linkage yields to one dominant cluster while the others are small and spatially split. Ward + Kendall yield to more consistent clusters with respect to the spatial structure of the system. However, I am able to get a similar spatial distribution using Pearson's correlation on Z standardized data with Ward linkage. This is even better if I apply a quantile mapping to a normal distribution on my time series. I guess it might be more be "mathematical" than relying on Kendall's tau.
            $endgroup$
            – Delforge
            Feb 19 at 10:26










          • $begingroup$
            Pearson does its own normalization... And it's easy to prove that it is related to Euclidean on appropriately preprocessed data. So if you do this math, you may be able to set it up so that you can use Euclidean (and hence Ward) to get Pearson results. You just need to show that you can pull out the normalization, and that it won't yield a division by 0 on your data.
            $endgroup$
            – Anony-Mousse
            Feb 19 at 11:50













          0












          0








          0





          $begingroup$

          The way Ward's linkage is computed really only makes sense with squared Euclidean type of measures. Only then the Konig-Huygens theorem can be used.



          Why don't you consider average linkage? Why Ward?






          share|improve this answer









          $endgroup$



          The way Ward's linkage is computed really only makes sense with squared Euclidean type of measures. Only then the Konig-Huygens theorem can be used.



          Why don't you consider average linkage? Why Ward?







          share|improve this answer












          share|improve this answer



          share|improve this answer










          answered Feb 18 at 20:07









          Anony-MousseAnony-Mousse

          5,010624




          5,010624











          • $begingroup$
            As it is a spatiotemporal dataset, I am able to check how clusters are spatially distributed. Kendall + Average linkage yields to one dominant cluster while the others are small and spatially split. Ward + Kendall yield to more consistent clusters with respect to the spatial structure of the system. However, I am able to get a similar spatial distribution using Pearson's correlation on Z standardized data with Ward linkage. This is even better if I apply a quantile mapping to a normal distribution on my time series. I guess it might be more be "mathematical" than relying on Kendall's tau.
            $endgroup$
            – Delforge
            Feb 19 at 10:26










          • $begingroup$
            Pearson does its own normalization... And it's easy to prove that it is related to Euclidean on appropriately preprocessed data. So if you do this math, you may be able to set it up so that you can use Euclidean (and hence Ward) to get Pearson results. You just need to show that you can pull out the normalization, and that it won't yield a division by 0 on your data.
            $endgroup$
            – Anony-Mousse
            Feb 19 at 11:50
















          • $begingroup$
            As it is a spatiotemporal dataset, I am able to check how clusters are spatially distributed. Kendall + Average linkage yields to one dominant cluster while the others are small and spatially split. Ward + Kendall yield to more consistent clusters with respect to the spatial structure of the system. However, I am able to get a similar spatial distribution using Pearson's correlation on Z standardized data with Ward linkage. This is even better if I apply a quantile mapping to a normal distribution on my time series. I guess it might be more be "mathematical" than relying on Kendall's tau.
            $endgroup$
            – Delforge
            Feb 19 at 10:26










          • $begingroup$
            Pearson does its own normalization... And it's easy to prove that it is related to Euclidean on appropriately preprocessed data. So if you do this math, you may be able to set it up so that you can use Euclidean (and hence Ward) to get Pearson results. You just need to show that you can pull out the normalization, and that it won't yield a division by 0 on your data.
            $endgroup$
            – Anony-Mousse
            Feb 19 at 11:50















          $begingroup$
          As it is a spatiotemporal dataset, I am able to check how clusters are spatially distributed. Kendall + Average linkage yields to one dominant cluster while the others are small and spatially split. Ward + Kendall yield to more consistent clusters with respect to the spatial structure of the system. However, I am able to get a similar spatial distribution using Pearson's correlation on Z standardized data with Ward linkage. This is even better if I apply a quantile mapping to a normal distribution on my time series. I guess it might be more be "mathematical" than relying on Kendall's tau.
          $endgroup$
          – Delforge
          Feb 19 at 10:26




          $begingroup$
          As it is a spatiotemporal dataset, I am able to check how clusters are spatially distributed. Kendall + Average linkage yields to one dominant cluster while the others are small and spatially split. Ward + Kendall yield to more consistent clusters with respect to the spatial structure of the system. However, I am able to get a similar spatial distribution using Pearson's correlation on Z standardized data with Ward linkage. This is even better if I apply a quantile mapping to a normal distribution on my time series. I guess it might be more be "mathematical" than relying on Kendall's tau.
          $endgroup$
          – Delforge
          Feb 19 at 10:26












          $begingroup$
          Pearson does its own normalization... And it's easy to prove that it is related to Euclidean on appropriately preprocessed data. So if you do this math, you may be able to set it up so that you can use Euclidean (and hence Ward) to get Pearson results. You just need to show that you can pull out the normalization, and that it won't yield a division by 0 on your data.
          $endgroup$
          – Anony-Mousse
          Feb 19 at 11:50




          $begingroup$
          Pearson does its own normalization... And it's easy to prove that it is related to Euclidean on appropriately preprocessed data. So if you do this math, you may be able to set it up so that you can use Euclidean (and hence Ward) to get Pearson results. You just need to show that you can pull out the normalization, and that it won't yield a division by 0 on your data.
          $endgroup$
          – Anony-Mousse
          Feb 19 at 11:50

















          draft saved

          draft discarded
















































          Thanks for contributing an answer to Data Science Stack Exchange!


          • Please be sure to answer the question. Provide details and share your research!

          But avoid


          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.

          Use MathJax to format equations. MathJax reference.


          To learn more, see our tips on writing great answers.




          draft saved


          draft discarded














          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fdatascience.stackexchange.com%2fquestions%2f45510%2fclustering-time-series-based-on-monotonic-similarity%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          Францішак Багушэвіч Змест Сям'я | Біяграфія | Творчасць | Мова Багушэвіча | Ацэнкі дзейнасці | Цікавыя факты | Спадчына | Выбраная бібліяграфія | Ушанаванне памяці | У філатэліі | Зноскі | Літаратура | Спасылкі | НавігацыяЛяхоўскі У. Рупіўся дзеля Бога і людзей: Жыццёвы шлях Лявона Вітан-Дубейкаўскага // Вольскі і Памідораў з песняй пра немца Адвакат, паэт, народны заступнік Ашмянскі веснікВ Минске появится площадь Богушевича и улица Сырокомли, Белорусская деловая газета, 19 июля 2001 г.Айцец беларускай нацыянальнай ідэі паўстаў у бронзе Сяргей Аляксандравіч Адашкевіч (1918, Мінск). 80-я гады. Бюст «Францішак Багушэвіч».Яўген Мікалаевіч Ціхановіч. «Партрэт Францішка Багушэвіча»Мікола Мікалаевіч Купава. «Партрэт зачынальніка новай беларускай літаратуры Францішка Багушэвіча»Уладзімір Іванавіч Мелехаў. На помніку «Змагарам за родную мову» Барэльеф «Францішак Багушэвіч»Памяць пра Багушэвіча на Віленшчыне Страчаная сталіца. Беларускія шыльды на вуліцах Вільні«Krynica». Ideologia i przywódcy białoruskiego katolicyzmuФранцішак БагушэвічТворы на knihi.comТворы Францішка Багушэвіча на bellib.byСодаль Уладзімір. Францішак Багушэвіч на Лідчыне;Луцкевіч Антон. Жыцьцё і творчасьць Фр. Багушэвіча ў успамінах ягоных сучасьнікаў // Запісы Беларускага Навуковага таварыства. Вільня, 1938. Сшытак 1. С. 16-34.Большая российская1188761710000 0000 5537 633Xn9209310021619551927869394п

          Partai Komunis Tiongkok Daftar isi Kepemimpinan | Pranala luar | Referensi | Menu navigasidiperiksa1 perubahan tertundacpc.people.com.cnSitus resmiSurat kabar resmi"Why the Communist Party is alive, well and flourishing in China"0307-1235"Full text of Constitution of Communist Party of China"smengembangkannyas

          ValueError: Expected n_neighbors <= n_samples, but n_samples = 1, n_neighbors = 6 (SMOTE) The 2019 Stack Overflow Developer Survey Results Are InCan SMOTE be applied over sequence of words (sentences)?ValueError when doing validation with random forestsSMOTE and multi class oversamplingLogic behind SMOTE-NC?ValueError: Error when checking target: expected dense_1 to have shape (7,) but got array with shape (1,)SmoteBoost: Should SMOTE be ran individually for each iteration/tree in the boosting?solving multi-class imbalance classification using smote and OSSUsing SMOTE for Synthetic Data generation to improve performance on unbalanced dataproblem of entry format for a simple model in KerasSVM SMOTE fit_resample() function runs forever with no result