Variations on Cross Correlations

조회 수: 8 (최근 30일)
Tim
Tim 2013년 7월 11일
I need a way to cross-correlate two signals which are not simply lagged copies of each other. The amplitudes are different (even when normalized) and one signal may show peaks where another does not. However, the overall geometry of the two signals should be the same (or rather, I'd like to find the lag(s) at which they overlap the 'best'). I also need to test if the lag changes through time.
For these two reasons, simple cross correlation (xcorr or in time series toolbox) will not work. To address the problem of changing lag, I have used timewindow_corr.m which searches for lags within time windows, as opposed to across the whole series. This seems to work well. I am, however, skeptical of the results because I am ignorant of what the cross correlation is doing to measure the similarity of the signals, which, as described above, have very different forms. I also get different results when using xcorr vs. time-window corr -- xcorr indicates a shift across the entire series; timewindow_corr indicates zero lag for all time windows considered.
Can anyone suggest a method for doing this in MatLab, or even what avenue is worth pursuing? Any help will be greatly appreciated.
Cheers,
T

답변 (1개)

Image Analyst
Image Analyst 2013년 7월 11일
Do you want to try normalized cross correlation? It's in the Image Processing Toolbox.
  댓글 수: 1
Tim
Tim 2013년 7월 11일
Thanks for replying! It sounds like a good idea, but I can't find anything for using it to compare two time series, over the same time interval. Can you suggest an approach? Also, would there be a way to make rolling or windowed calculations of correlation?

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Correlation and Convolution에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by