www.gusucode.com > graphics 案例源码程序 matlab代码 > graphics/CreateParetoChartExample.m

    %% Create Pareto Chart
% Create a Pareto chart of vector |y|.

% Copyright 2015 The MathWorks, Inc.


y = [90,75,30,60,5,40,40,5];
figure
pareto(y)

%%
% |pareto| displays the elements in |y| as bars in descending order and
% labels each bar with its index in |y|. Since |pareto| displays only the
% first 95% of the cumulative distribution, some elements in |y| are not
% displayed.