Appropriate window from accelerometer data
6 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti
I am attempting to put my data through the fat function however, it seems that due to high spikes at the ends I may need to use a window or/and a low pass filter. I am completely new to this and I am unsure how to go about this. For example should I use the Blackman-Harris filter? If I do how do I work the value for N etc.
Sorry for such a basic question
Bran
Risposte (8)
Wayne King
il 17 Dic 2013
By the "fat" function, did you really mean fft()?
The question is, do you really need the data at the ends? If you trying to estimate periodicities in the data, then maybe you just don't need that data. Especially if you have a sufficient number of data points, you can just select a representative section of the data where the data is "stationary".
If you want to try windowing, you simply form a window function equal in length to your data and then multiply your data element by element
x = randn(1500,1);
win = hamming(1500);
y = x.*win;
I would not worry too much about the type of window -- a Blackman window is just
win = blackman(1500);
Also, since you have the Signal Processing Toolbox, why not just periodogram() instead of fft()?
0 Commenti
Wayne King
il 17 Dic 2013
If the data is nonstationary, then:
Yes, if you can clearly section the data by condition, you can divide your data into sections and then window each section followed by Fourier analysis.
Or you can do a spectrogram.
It sounds like if you have 3 experimental conditions where you know the start and stop times of data collection, then the former would work well.
0 Commenti
Bran
il 18 Dic 2013
2 Commenti
Wayne King
il 18 Dic 2013
I'm assuming that you your x is a row vector because window is a column vector, try
x = x';
y = x.*win;
Bran
il 19 Dic 2013
Modificato: Wayne King
il 19 Dic 2013
1 Commento
Wayne King
il 19 Dic 2013
I don't see any plot of your data attached anywhere.
Yes, the above code will not work because you are padding the fft() but then you create a frequency vector just based on the length of the signal, so those lengths will not match.
Vedere anche
Categorie
Scopri di più su Blackman in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!