Signal Processing with SMOOTH

A simple way to smooth out the NOISY data set created in the previous example is to use IDL's SMOOTH function. It returns an array smoothed with a boxcar average of a specified width.

  1. Create a new variable to hold the smoothed data set by entering the following command:
  2. SMOOTHED = SMOOTH(noisy, 5)

  3. Now plot your new data set:
  4. IPLOT, SMOOTHED, VIEW_TITLE='Smoothed Data'

    The TITLE keyword draws the title text centered over the plot. Notice that while SMOOTH did a fairly good job of removing noise spikes, the resulting amplitudes taper off as the frequency increases.
    gssig04.gif

See the next example for another method of reducing noise in the data set.