view Code/Descriptors/yin/private/src/rsmooth.m @ 2:5fd388fdd6ef

initial commit - this file allows the programmer to select which of the PRAAT generated metrics the user wishes to use for classification, and then applies the k-means classifier.
author Dawn Black <dawn.black@eecs.qmul.ac.uk>
date Mon, 10 Sep 2012 09:18:15 +0100
parents ea0c737c6323
children
line wrap: on
line source
%y=rsmooth(x,smooth,npasses,trim) - smooth by running convolution
%
% X: input matrix
% SMOOTH: samples - size of square smoothing window
% NPASSES: number of smoothing passes (default=1)
% TRIM: if true, clip Y to same size as X
% 
% Y: output matrix
%
% RSMOOTH smooths each column of matrix X by convolution with a square window
% followed by division by the window size.
% Multiple passes allow smoothing with a triangular window (npasses=2), or
% window shapes that approach a gaussian (npasses large).  Convolution is
% implemented as a running sum for speed.
% 
% Y has NPASSES*(SMOOTH-1) more rows than X unless TRIM is set.
%
% mex function