Mercurial > hg > emotion-detection-top-level
view Code/Test/plotAudioFrameByType.m @ 0:ea0c737c6323
first commit
author | Dawn Black <dawn.black@eecs.qmul.ac.uk> |
---|---|
date | Thu, 26 Jul 2012 14:46:25 +0100 |
parents | |
children | 92ca03a8fa99 |
line wrap: on
line source
function plotAudioFrameByType( x, noOfValidFrames, vuv, frameLength ); hold on for frameIdx = 1:noOfValidFrames startPoint = ((frameIdx-1) * frameLength)+1; endPoint = frameIdx * frameLength; % if( vuv( frameIdx ) == 0 ) %silent % plot( startPoint : endPoint , x( startPoint : endPoint ), 'w' ); if( vuv( frameIdx ) == 1 ) % voiced plot( startPoint : endPoint , x( startPoint : endPoint ), 'y' ); elseif( vuv( frameIdx ) == 2 ) %unvoiced plot( startPoint : endPoint , x( startPoint : endPoint ) , 'r' ); end end hold off