Pareto chart not displaying all inputs (some too small(?))
Afficher commentaires plus anciens
Hi all,
I want to use a pareto chart to illustrate error components of a total error on a measurement. I wrote:
Er_components = [e1^2,e2^2,e3^2,e4^2,e5^2];
Er_cat = {'Precision', 'Load Cell Accuracy', 'Resolution', 'DAQ gain', 'DAQ offset'};
pareto(Er_components,Er_cat);
ylabel('(Total Error)^{2} on Voltage Measurement (mV/V)^{2}');
title('Error Contribution at Low Re');
The only issue is that 3/5 are very small once squared, and the chart wont display the cateogories. I was wondering if there was a way to get it to display the other factors.

Réponses (1)
Cris LaPierre
le 3 Déc 2020
Modifié(e) : Cris LaPierre
le 3 Déc 2020
"By default, either the tallest 10 bars or first 95% of the cumulative distribution is displayed, whichever is smaller."
The example here shows how to display all values in the cumulative distribution. Below I've modified your example as well (using made up error values).
e1 = 0.0025;
e2 = 0.0374;
e3 = 0.005;
e4 = 0.0255;
e5 = 0.001;
Er_components = [e1^2,e2^2,e3^2,e4^2,e5^2];
Er_cat = {'Precision', 'Load Cell Accuracy', 'Resolution', 'DAQ gain', 'DAQ offset'};
pareto(Er_components,Er_cat,1); % add a third input, ",1" to display all values
ylabel('(Total Error)^{2} on Voltage Measurement (mV/V)^{2}');
title('Error Contribution at Low Re');
5 commentaires
Caitlin Taylor
le 3 Déc 2020
Caitlin Taylor
le 3 Déc 2020
What version of MATLAB are you using? I am running your code here in this window using 2020b, so the results you see here are what you should get. Here I've updated it to use your values.
e1= 0.0022;
e2 = 0.0373;
e3 = 1.49 *10^-6;
e4 = 1.42 *10^-9;
e5 = 0.025;
Er_components = [e1^2,e2^2,e3^2,e4^2,e5^2];
Er_cat = {'Precision', 'Load Cell Accuracy', 'Resolution', 'DAQ gain', 'DAQ offset'};
pareto(Er_components,Er_cat,1); % add a third input, ",1" to display all values
ylabel('(Total Error)^{2} on Voltage Measurement (mV/V)^{2}');
title('Error Contribution at Low Re');
Caitlin Taylor
le 3 Déc 2020
Cris LaPierre
le 3 Déc 2020
It appears this functionality was first added in R2020a.
Catégories
En savoir plus sur MATLAB dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!


