28 January 2010 0 Comments

Robust Signal Smoothing Method in Matlab (smoothN)

Damien Garcia has produced a 1-D to N-D robust smoothing matlab file to allow fast and robust smoothing of one-dimensional and multidimensional data w/wo missing values.

A simple example for signal:

y = cos(x/10)+(x/50).^2 + randn(size(x))/10;

y([70 75 80]) = [5.5 5 6];

is shown below:

smoothn

In a continuous time domain, this might be like this:

smoothn2

You know might know why the algorithm is robust.

Reference

Garcia D, Robust smoothing of gridded data in one and higher dimensions with missing values. Computational Statistics & Data Analysis, 2009, doi:10.1016/j.csda.2009.09.020 (PDF).

Narasimha M. et al, On the computation of the discrete cosine transform, IEEE Trans Comm, 26, 6, 1978, pp 934-936.

FYI: The DCT is closely related to the discrete Fourier transform. You can often reconstruct a sequence very accurately from only a few DCT coefficients, a useful property for applications requiring data reduction.

Tags: