Skip to main content
QUICK REVIEW

[Paper Review] An Experimental Evaluation of Nearest Neighbour Time Series Classification

Anthony Bagnall, Jason Lines|arXiv (Cornell University)|Jun 18, 2014
Time Series Analysis and ForecastingComputer Science9 references41 citations
TL;DR

This paper evaluates nearest neighbour time series classification using 77 datasets, demonstrating that 1-NN with DTW and cross-validated window size significantly outperforms standard baselines. It finds that Euclidean 1-NN is easily beaten by simpler classifiers, but DTW with optimized windowing is robust and superior, while DTW weighting offers no significant advantage over window optimization.

ABSTRACT

Data mining research into time series classification (TSC) has focussed on alternative distance measures for nearest neighbour classifiers. It is standard practice to use 1-NN with Euclidean or dynamic time warping (DTW) distance as a straw man for comparison. As part of a wider investigation into elastic distance measures for TSC~\cite{lines14elastic}, we perform a series of experiments to test whether this standard practice is valid. Specifically, we compare 1-NN classifiers with Euclidean and DTW distance to standard classifiers, examine whether the performance of 1-NN Euclidean approaches that of 1-NN DTW as the number of cases increases, assess whether there is any benefit of setting $k$ for $k$-NN through cross validation whether it is worth setting the warping path for DTW through cross validation and finally is it better to use a window or weighting for DTW. Based on experiments on 77 problems, we conclude that 1-NN with Euclidean distance is fairly easy to beat but 1-NN with DTW is not, if window size is set through cross validation.

Motivation & Objective

  • To empirically test whether 1-NN with Euclidean distance remains a valid baseline for time series classification (TSC) compared to other classifiers.
  • To investigate whether 1-NN with DTW outperforms 1-NN with Euclidean distance as training set size increases.
  • To evaluate whether setting k in k-NN via cross-validation improves performance over 1-NN.
  • To determine whether optimizing the DTW warping window size through cross-validation enhances accuracy.
  • To compare the effectiveness of windowing versus weighting in DTW for TSC.

Proposed method

  • Conducted over 3 million experiments across 77 time series classification problems, including 43 from the UCR repository, 24 from prior research, and 5 new electricity device datasets.
  • Evaluated 1-NN classifiers using Euclidean distance, DTW, LCSS, DDTW, WDTW, and WDDTW with full window and parameter-optimized variants.
  • Used 10-fold cross-validation to tune k for k-NN and the warping window size for DTW, ensuring fair comparison across all methods.
  • Applied parameter optimization for all classifiers on the training set, including the weighting parameter g in WDTW and WDDTW.
  • Reported results using average ranks and critical difference diagrams to assess statistical significance across methods.
  • Performed statistical testing at the 5% significance level to determine whether performance differences were meaningful.

Experimental results

Research questions

  • RQ1Is 1-NN with Euclidean distance a meaningful baseline for new TSC algorithms, or is it easily outperformed by simpler classifiers?
  • RQ2Does the accuracy of 1-NN with Euclidean distance converge to that of 1-NN with DTW as the number of training cases increases?
  • RQ3Is it beneficial to set k in k-NN via cross-validation, or is 1-NN sufficient?
  • RQ4Is it worthwhile to optimize the DTW warping window size through cross-validation?
  • RQ5Does the weighted DTW (WDTW) algorithm provide a significant performance improvement over standard DTW with a window, or is window optimization sufficient?

Key findings

  • 1-NN with Euclidean distance is easily outperformed by standard classifiers (e.g., tree-based or probabilistic) without any parameter tuning, making it a weak baseline.
  • 1-NN with DTW and a full warping window is significantly outperformed by 1-NN with DTW when the window size is optimized via cross-validation, with a mean accuracy improvement of 1.8%.
  • Setting k through cross-validation provides no significant benefit over 1-NN, indicating that 1-NN is sufficient for DTW-based classification.
  • The weighting scheme in WDTW offers no significant improvement over DTW with cross-validated window size, with a mean difference in accuracy of only 0.0056.
  • LCSS performs surprisingly well on image and motion data, suggesting subsequence matching techniques may be more effective than global alignment for certain problem types.
  • There is no significant difference between the top four classifiers (DTWCV, WDTW, LCSS, and DDTW), but all significantly outperform full-window DTW and Euclidean distance.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.