Showing posts with label dynamic time warping. Show all posts
Showing posts with label dynamic time warping. Show all posts

Sunday, September 18, 2011

DTW: dynamic time warping 动态时间规整

Basically, DTW (dynamic time warping) is an algorithm to output cumulative distance of two time sequences, which is widely used e.g. for classification and clustering.

For example, when using k-mean for clustering, we can use DTW as distance function. Here is one of such nice instances (using R: http://www.rdatamining.com/examples/ts-mining)

Relevant information from Anshul's email.  

Code:

Python code: https://mlpy.fbk.eu/
MATLAB: the samplealign() function in the bioinformatics toolbox does DTW

There is also the global alignment kernel that is faster and more accurate that DTW. It can be used to compute distance between time series to be used in clustering allowing for all possible global alignments. Here is code http://www.iip.ist.i.kyoto-u.ac.jp/member/cuturi/GA.html
Here is an example (in Chinese) from Ckary's blog: