Findpeaks for powerspectrum ignores maxima at first or last index of power spectrum array.
2 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
I am trying to use findpeaks to get teh full width half maximum of band different peaks in a power
spectrum. I have used a dummy signal which is a simple sine wave sinx+ sin7x with some noise, but I can see from my power spectrum that there are two frequencies as expected, but findpeaks will only identify peaks that are not at the very first index.
I have enclosed an example. The annotated peak is the only one identified. The other peak, which is the maximum value as well, is completely neglected so I cannot get the width at half max data from it. ![Screen Shot 2019-12-19 at 3.00.15 PM.png](https://www.mathworks.com/matlabcentral/answers/uploaded_files/256400/Screen%20Shot%202019-12-19%20at%203.00.15%20PM.png)
![Screen Shot 2019-12-19 at 3.00.15 PM.png](https://www.mathworks.com/matlabcentral/answers/uploaded_files/256400/Screen%20Shot%202019-12-19%20at%203.00.15%20PM.png)
9 commentaires
dpb
le 20 Déc 2019
Modifié(e) : dpb
le 20 Déc 2019
"fft and multiplying the the complex conjugate."
NB: The normalization of 2X the 2-sided spectrum for one-sided should NOT include either the DC or Fmax bins; there's only one of them each and all the energy is already there. If don't account for, the apparent DC component is twice the magnitude should be.
See the example at doc fft; it does account for this.
Réponses (0)
Voir également
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!