MA (Moving Average) Spectrum
This MA (Moving Average) Spectrum option in the Spectral menu or the Spectral toolbar generates models that are useful for characterizing the sharp nulls that are present in some signals and in most noise backgrounds.
Whereas an AR autoregressive model produces an "all-pole" frequency spectrum, an MA model produces an "all-zero" spectrum. An MA spectral model is non-linear in nature. It models peaks quite poorly as very high orders are usually needed and even then spectral resolution is generally poor. It can, however, accurately model the sharp nulls in signals in much the same manner that an AR algorithm accurately maps the spectral peaks.
A moving average procedure is not a high-resolution spectral estimator. It may be of value in modeling backgrounds and other data lacking narrowband components. An MA algorithm is an appropriate choice for a data set that lacks sharp spectral peaks but contains deep nulls.
Algorithm
There are three MA algorithms in AutoSignal. The Durbin procedure is a non-optimal linear MA algorithm that offers fast computation of the MA parameters. The NL procedure fits the MA parameters non-linearly, and the NL SF procedure assures stable MA coefficients by adding spectral factorization to each iteration. Although the NL fits are appreciably slower, they produce considerably better least-squares goodness of fit values.
Model Order Selection
In a manner analogous to AR model fitting, the minimum order needed will be twice the number of nulls evident in the spectrum.
Spectrum
An MA spectrum can be generated directly from the MA coefficients, or with some performance benefits using an FFT. The Full Range option locks the 0-0.5 Nyquist range. It also causes the spectrum to be generated via an FFT if the Adaptive option is disabled. When the Full Range option is on, only the total spectral count (n) can be specified. This option specifies the total frequency count in the output spectrum. An FFT of 16384 points produces 8193 spectral frequencies from 0 to 0.5 normalized frequency. For the Full Range option, it will be fastest if the values in the drop down box for n are used, since these produce power of 2 FFTs. This option uses the Best Exact n FFT procedure.
If the Full Range option is off, you can select the desired start and end frequencies as well as the count of spectral frequencies (n) in this band. It is thus possible to generate a detailed spectrum only in the region of specific interest. This option uses a direct computation for the spectrum and any size can be used.
The Adaptive option always uses a direct computation for the spectrum. It uses a Runge-Kutta procedure to integrate the spectrum adaptively, saving the points used in the computation of the integral. This results not only in an adaptive frequency set containing frequencies concentrated near the peaks, but also in an accurate area under the spectrum.
If the Adaptive option is used, it is possible to Normalize the spectrum so that its integrated power matches that of the input data. The Adaptive integration seeks 1E-5 fractional convergence.
The areas under the peaks are indicative of estimated power, and as such, this adaptive integration uses partitions formed by midpoints of the local maxima-determined peak positions. The Numeric Summary offers this numeric integration.
Plot
For MA spectra, there are only four formats. The PSD can reflect the three different power normalizations, or it can be expressed in dB.
The power values from peak integration may be quite limited in accuracy. This is true even when the adaptive integration achieves the target fractional error since the envelope of an MA peak is a poor representation of a sinusoid. For true harmonics, the linear least-squares sinusoidal fit in the Numeric Summary will almost certainly be more accurate, and the Non-Linear Optimization better still.
MA peak labels consist of frequencies only. They are toggled on and off with the Display
Maxima button. The spectral peaks are identified by first generating a spectrum with a count of
8193 equally spaced frequencies. These peaks are then further refined using a one-dimensional minimization
procedure with the continuous spectral model. The peak frequencies are estimated to 1E-15 precision. Note
that each local maximum in the 8193 frequency count spectrum is treated as a valid spectral peak. The
spectral peak count can therefore be as high as half the model order.
Add Noise
It may be instructive to see where a given procedure starts to break down as a consequence of temporarily adding white observation noise to the input data. The zero noise level is S/N=300dB (fractional noise=1E-15, the IEEE double precision threshold for addition). At this value, no noise is added to the data. A value of 280 would add noise in the 14th significant figure, 260 in the 13th, 240 in the 12th and so on. This option assumes that the current data set is entirely signal, and adds noise accordingly. Typical test values are 40dB(1% noise), 20(10%), 10(31.6%), 6(50.1%), 3(70.8%), and 0(100%).
List
The List Data option lists the index, frequency, and the spectral
quantity currently plotted. The listing uses the AutoSignal text
viewer facility.
Copy
The Copy Data to Clipboard option copies the frequency and the spectral quantity currently plotted
to the clipboard. Formats include full precision binary (for spreadsheets such as Excel) and ASCII (for
pasting into text editors). You can generally find a Paste As option in most applications if you want
specific control over the format imported.
Save
The Save Data to Disk option writes the frequency and and the spectral
quantity currently plotted to a supported file format. These formats include ASCII, Excel 97, Excel 95,
Lotus WK3, Lotus WK1, SPSS, or Systat.
Production Facility
The AutoSignal
Automation facility allows unattended processing of large numbers of data sets. The data sets can
be consolidated in an Excel file or acquired using a DLL. The numeric summaries and graphs can be exported
to an MS Word RTF file, while the extended data summaries or the current spectra can be exported to an
Excel 95 or Excel 97 file.
Numeric Summary
The Numeric
Summary offers a full MA report. The report optionally includes a listing of the coefficients, component
powers by numeric integration, MA fit estimation details, and a linear sinusoidal least-squares fit summary.
Non-Linear Optimization
The Non-Linear
Optimization offers the means to refine the parameter estimates given in the linear sinusoidal fit
that is reported in the Numeric Summary. Constrained least-squares and robust (maximum likelihood) non-linear
fitting is available with either sinusoid or damped sinusoid models.
Rich-Text Format Export
The Export Numeric Summary and Graph to RTF File option writes
the numeric summary and spectral plot to an RTF
file. The numeric portion of the file is based upon the current settings in the Numeric Summary option.
The text data will be written to portrait orientation pages. The graph uses the current settings and size
of the spectral plot, and is inserted as a Windows
Metafile. The graph always uses a landscape orientation. Beyond a certain size, the graph utilizes
a full landscape page.
View Residuals
Because a fitting occurs, the residuals
can be inspected to see if they are normally distributed. The SNP plot is particularly useful.
Plot Roots
The zeros of the MA model can be inspected with the Plot
Roots option. The root plot displays o’s (zeros) instead of +’s (poles).
Toggle Popup Information Window
Because the MA spectrum is a fitting procedure, a host of statistics
are available to describe the MA model fit. The Toggle Popup Information
Window is used to show or hide this information. The r²
goodness of fit index may be particularly useful, since spectra that visually appear to be well fitted
may be the result of a poor deterministic fit. A smooth MA spectrum is not an indicator of an accurate
model fit. A high r²
(0.95+) is not needed for good frequency estimation, but it is necessary for accuracy in the numerical
integrations.
Local Options
A local option changes the data set for the duration of the current procedure only. The main data table is not altered. AutoSignal offers four local options in most of the spectral procedures.
Section
the data to isolate specific regions for processing.
Detrend
for removing mean or subtracting a least-squares trend model.
Fourier
Filtration for isolating spectral components by frequency.
Eigendecomposition
Filtration for isolating spectral components by signal strength.
The Reset button restores the data to its state when first entering
the procedure. Note that if you implement sequential local procedures, all of the revisions are discarded
upon reset. If an Automation
Session is in progress, the Reset button can be used to terminate
the automated processing.
![]() |