tomwalters@0: .TH SMOOTH 1 "1 September 1993" tomwalters@0: tomwalters@0: .SH NAME tomwalters@0: smooth \- Data smoothing by convolution with Gaussian window. tomwalters@0: tomwalters@0: .SH SYNTAX tomwalters@0: smooth [options] [file] tomwalters@0: tomwalters@0: .SH DESCRIPTION tomwalters@0: Low-pass filter by convolving the input with a unit area Gaussian window tomwalters@0: in the time or frequency domain. tomwalters@0: The transform between domains uses the FFT. tomwalters@0: tomwalters@0: tomwalters@0: .SH OPTIONS tomwalters@0: tomwalters@0: 1. length tomwalters@0: tomwalters@0: The amount of input to smooth in time units (ms or s) or samples (no units). tomwalters@0: Time units are converted to samples using the given `samplerate' option. tomwalters@0: The string "max" is recognised as the remainder of input. tomwalters@0: tomwalters@0: 2. domain tomwalters@0: tomwalters@0: Select algorithm for smoothing. tomwalters@0: In the time domain ("domain=time") the discrete convolution formula is applied tomwalters@0: directly as a local averaging operation on the input with weights obtained tomwalters@0: by time-reversing and shifting a Gaussian window. tomwalters@0: In the frequency domain ("domain=frequency") the FFT of the whole input is tomwalters@0: multiplied by a Gaussian frequency response function (the FFT of the tomwalters@0: Gaussian window), and the result inverse FFT'd. tomwalters@0: tomwalters@0: 3. variance, range tomwalters@0: tomwalters@0: The variance of the Gaussian window and its tomwalters@0: ordinal range in standard deviations either side of the mode. tomwalters@0: The window is assumed to be zero for all time outside the specified range. tomwalters@0: These parameters control the size of the window and consequently the amount tomwalters@0: of smoothing. The larger the variance, the more smoothing. tomwalters@0: The size of the window is given by: tomwalters@0: tomwalters@0: .nf tomwalters@0: [ 2 * range * sqrt( variance ) ] samples + 1 sample tomwalters@0: .fi tomwalters@0: tomwalters@0: The variance can be given with time units (ms or s) or samples (no units). tomwalters@0: Time units are converted to samples using the given `samplerate' option. tomwalters@0: tomwalters@0: 4. type tomwalters@0: tomwalters@0: The input and output data type. Recognised types are "short" and "float". tomwalters@0: tomwalters@0: .SH "SEE ALSO" tomwalters@0: options gauss filt1 conv tomwalters@0: tomwalters@0: .SH COPYRIGHT tomwalters@0: .LP tomwalters@0: Copyright (c) Applied Psychology Unit, Medical Research Council, 1995 tomwalters@0: .LP tomwalters@0: Permission to use, copy, modify, and distribute this software without fee tomwalters@0: is hereby granted for research purposes, provided that this copyright tomwalters@0: notice appears in all copies and in all supporting documentation, and that tomwalters@0: the software is not redistributed for any fee (except for a nominal tomwalters@0: shipping charge). Anyone wanting to incorporate all or part of this tomwalters@0: software in a commercial product must obtain a license from the Medical tomwalters@0: Research Council. tomwalters@0: .LP tomwalters@0: The MRC makes no representations about the suitability of this tomwalters@0: software for any purpose. It is provided "as is" without express or tomwalters@0: implied warranty. tomwalters@0: .LP tomwalters@0: THE MRC DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING tomwalters@0: ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL tomwalters@0: THE A.P.U. BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES tomwalters@0: OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, tomwalters@0: WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, tomwalters@0: ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS tomwalters@0: SOFTWARE. tomwalters@0: