tomwalters@0: % method of class @signal tomwalters@0: % function sig=generategauss(sig,pos,hight,sigma) tomwalters@0: % INPUT VALUES: tomwalters@0: % sig: original @signal with length and samplerate tomwalters@0: % pos: medium of the curve tomwalters@0: % hight: its height tomwalters@0: % sigma: and its standart derivation tomwalters@0: % produces a gaussian bell curve with the parameters tomwalters@0: % tomwalters@0: % RETURN VALUE: tomwalters@0: % sig: @signal tomwalters@0: % bleeck@3: % This external file is included as part of the 'aim-mat' distribution package bleeck@3: % (c) 2011, University of Southampton bleeck@3: % Maintained by Stefan Bleeck (bleeck@gmail.com) bleeck@3: % download of current version is on the soundsoftware site: bleeck@3: % http://code.soundsoftware.ac.uk/projects/aimmat bleeck@3: % documentation and everything is on http://www.acousticscale.org bleeck@3: tomwalters@0: tomwalters@0: function sig=generategauss(sig,pos,hight,sigma) tomwalters@0: tomwalters@0: vals=1:getnrpoints(sig); tomwalters@0: tomwalters@0: evals=exp(-(pos-vals).^2/(2*sigma^2)); tomwalters@0: tomwalters@0: evals=evals*hight; tomwalters@0: tomwalters@0: sig=setvalues(sig,evals); tomwalters@0: