Density measurment using cumulative plots
Ältere Kommentare anzeigen
I have two plots
plot(a,b)
hold on
plot(c,d)
and now i need do:

Akzeptierte Antwort
Weitere Antworten (3)
Zuzana Pániková
am 2 Mär. 2022
0 Stimmen
1 Kommentar
Image Analyst
am 2 Mär. 2022
I don't know. What are the two mat files and the xlsx file in the zip file? Which is yRed, yBlue, and the x values?
Zuzana Pániková
am 4 Mär. 2022
0 Stimmen
Image Analyst
am 4 Mär. 2022
One way is to simply sum the curves and subtract them.
area = abs(sum(d) - sum(b));
That assumes there are no negative values, the curves don't cross, and treats the values like a bar chart (bars with flat tops). If you want to treat them like quadilaterals (like bars but slanted tops), you can use trapz().
1 Kommentar
Zuzana Pániková
am 5 Mär. 2022
Kategorien
Mehr zu Numerical Integration and Differentiation finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!

