CaptainProg
CaptainProg

Reputation: 5690

Signal analysis: amplitude estimation in MATLAB

I am trying to estimate the amplitude of a signal in MATLAB:

signal

As can be seen, I can't simply take the max() and min() to get the amplitude. The signal continually wanders, and in any case isn't constant. However, all that I'm looking for is an average - one single figure that estimates the average amplitude of the dominant component in the figure above (which repeats eight times). Visually, it's fairly obvious what I'm trying to find out. Programatically however...

I have heard tell of 'Hilbert transform' - hilbert() - and 'fast fourier transform' - fft() - but have very little knowledge of signal analysis - and wonder if anyone might be able to steer me in the right direction, or explain how to utilise either of these functions. My data is simply a float stored in a one-dimensional array at 1000Hz.

Any help gratefully received!

Upvotes: 1

Views: 4831

Answers (2)

zellus
zellus

Reputation: 9592

In order to extract the peak-to-peak amplitude, you may first apply detrend to your dataset.

Upvotes: 1

Ben Voigt
Ben Voigt

Reputation: 283624

You have several options, the easiest of which would be:

  1. Use a peak detector to find local extrema. You can find several on the MathWorks File Exchange.
  2. Apply a high pass filter to remove the baseline drift, then find the absolute minimum and maximum

Upvotes: 2

Related Questions