How to get xcorr results in coef between 0 and 1 when comparing 2 wave sound with different length ?

soundA = Path_of_soundA.wav;
soundB = Path_of_soundB.wav; %%soundA and soundB have not the same length
[C1,lag1] = xcorr(soundA,soundB);
avv = max(xcorr(soundA,soundB));
fprintf(['\n avv = ', num2str(avv)]); %%I want something between 0 and 1. Something that I
%%know the limit

回答 (1 件)

You can try
xcorr(soundA,soundB,'coeff')
HTH

1 件のコメント

Joel Sande
Joel Sande 2015 年 7 月 29 日
It doesn't work.
It works only if soundA and soundB have the same length.

サインインしてコメントする。

質問済み:

2015 年 7 月 20 日

コメント済み:

2015 年 7 月 29 日

Community Treasure Hunt

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

Start Hunting!

Translated by