Capability analysis CPK vs PPK calculation?

조회 수: 11 (최근 30일)
Cailin
Cailin 2023년 10월 23일
답변: Abhaya 2024년 8월 9일
The S = capability(data,specs) function provides a capability analysis with resultant CPK (capability within subgroups), is there a way to calculate PPK (overall capability) for a data set?

답변 (1개)

Abhaya
Abhaya 2024년 8월 9일
Hi,
I understand you want to calculate process performance index.
I have calculated the Ppk value for vector ‘x’ using following code. I have set the lower specification limit (LSL) = 9.8 and upper specification limit (USL) = 10.2 .
The code is as follows:
function S=ppkCalc(data,spec)
%claculate mean
S.mu=mean(mean(data));
%find the sum of square of each number
sumSq=sumsqr(data);
%find standard deviation
sz=size(data);
n=sz(1)*sz(2);
S.sigma=sqrt((sumSq-n*(S.mu^2))/(n-1));
LSL=spec(1);
USL=spec(2);
S.Ppk=min((S.mu-LSL)/(3*S.sigma),(USL-S.mu)/(3*S.sigma));
end
% the following measurement are for five different objects with target of 10 and tolerance 0.2
mat=[10.1 10.0 9.9 10.2 10.0;
10.0 10.1 9.8 10.2 10.1;
10.3 10.0 10.1 9.9 10.2;
10.0 9.9 10.1 10.0 10.2;
9.8 10.1 10.0 10.2 10.0];
%call the function
x=ppkCalc(mat,[9.8 10.2])
x = struct with fields:
mu: 10.0480 sigma: 0.1295 Ppk: 0.3913

카테고리

Help CenterFile Exchange에서 Least Squares에 대해 자세히 알아보기

제품


릴리스

R2023b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by