Take the 2-minute tour ×
Cross Validated is a question and answer site for people interested in statistics, machine learning, data analysis, data mining, and data visualization. It's 100% free, no registration required.

I have two time series, series1 and series2. My aim is to find how much Series2 is different from Series1, automatically/quantitatively.
Image can be seen in its original size by clicking here. alt text

Series1 is the expected result. Series2 is the test/incoming series.

I am providing a histogram plot, where Series2 is represented in dark brown colour. You can also note in the x-axis between 221 and 353 there is a significant variation. ie Series2 is less than Series1. I am coding using C++.

I think, crosscorrelation will help, but produces a value based on similarity rather than dissimilarity. I see people talk about Kolmogorov-Smirnov Test. Is this the test which i should be performing?

UPDATE 1: I am trying to perform a template matching. I have divided my template image in to 8x8 blocks as well as my incoming test image. I am trying to compare one block in template image with the same block(based on the spatial pixel positions) in the test image. I calculate the intensity sum within each block. I obtain series1 for the Template image and have Series2 for the test image.

share|improve this question
1  
I would suggest you to work on clarity of the question; this helps in getting answers. –  mbq Oct 21 '10 at 10:56
    
@mbq, i have updated to my post –  Raj Oct 21 '10 at 11:15
add comment

1 Answer

There are many different distance measures. For starters, there's always the correlation.

You can look at the mean square error. In R, you can see the algorithm for time series in Rob Hyndman's ftsa package (see the error function).

See Liao (2005) for a nice short survey of time series similarity measures, including euclidean distance, root mean square distance, mikowski distance, pearson's correlation, dynamic time warping distance, kullback-liebler disance, symmetric Chernoff information divergence, and cross-correlation.

share|improve this answer
    
Thanks for your input. Will test this approach and will update. Also, do you think, i can use Kolmogorov-Smirnov Test in my case. Please see the plot, img254.imageshack.us/img254/9645/25971376.gif –  Raj Oct 22 '10 at 8:40
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.