find peaks of excel graph
10 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Hello everyone,
I'm having some trouble with finding the peak coordinates of my excel data. The data has x and y values which i graphed, but i used findpeaks(data) and that did not work. I'm trying to have those peaks labeled as well if that is possible. Any help/suggestions are welcomes. Thank you
here is the graphs
here is what my code looks like
% graph
filename = 'HDPE-WAXS.xlsx';
which -all xlsread
DATA1 = readtable('HDPE-WAXS.xlsx');
%dintensity vs 2theta
intens = DATA1{:,2}; % intensity
twotheta = DATA1{:,4}; % 2theta
%plot of xrd hdpe
figure(1)
plot(twotheta,intens,'r')
xlabel('2theta (deg)')
ylabel('intensity (couts/sec)')
title('WAXS-XRD of HDPE')
2 Kommentare
AH
am 18 Apr. 2024
You may want to try different options such as NPeaks, MinPeakHeight, ...
If you upload your data, we can provide you with a working syntax.
Voss
am 18 Apr. 2024
"i used findpeaks(data) and that did not work"
Do you mean findpeaks(intens)? If that didn't work, you may need to adjust the parameters you specify in the findpeaks call:
For more specific help/suggestions, please upload the xlsx file using the paperclip button.
Antworten (1)
Cris LaPierre
am 18 Apr. 2024
I recommend using the Find Local Extrema live task in a live script. It is an interactive way to determine the appropriate settings for the detecting peaks in your specific data set.
0 Kommentare
Siehe auch
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!