Dew Stats Master .NET
QCCumSumChart Routine
Summary
Constructs CUMSum chart.

Unit
StatControlCharts

Declaration
Procedure QCCumSumChart(Data: TMtx; DrawVec: TVec; k, h: TSample; mean: TSample; sigma: TSample = 1.0; SHigh: TVec = nil; SLow: TVec = nil; Confidence: TSample = 0.997);
 Parameter  Description 
Data Each Data row contains replicated observation taken at specific time. 
Confidence Confidence level for upper and lower control limit. Confidence must lie in the (0,1) interval. 
DrawVec Returns values to be drawn. 
mean Defines the estimate of the in-control mean. 
sigma Defines known (or estimated) standard deviation of the sample means. 
Design parameter of the V-mask. k is the rise in the V-arm corresponding to one sampling unit. 
Design parameter of the V-mask. h defines the rise in the arm coresponding to the distance from the origin to point vertex. 
SHigh If set, returns high values for cumsum plot. When SHigh exceeds value h, the process is said to be out-of-control. Compare SHigh values to h to find if a process is out-of-control. 
SLow If set, returns low values for cumsum plot. When SLow exceeds value h, the process is said to be out-of-control. Compare SLow values to h to find if a process is out-of-control. 

Description
Calculates CumSum Chart drawing values and additonal values, needed for deciding if some samples are out-of-control. See http://www.itl.nist.gov/div898/handbook/pmc/section3/pmc323.htm to learn more about Cumsum QC charts.
Categories
Control charts

Example 1

Perform CumSum QC to determine if process is out-of-control.
var h,k,m,s: TSample; data: Matrix; sh,sl, s,outofcontrol: Vector; begin data.LoadFromFile('process_data.mtx'); // estimate k=0.32, h = 4.7 k := 0.32; h := 4.7; // estimate process mean and sigma m := 230.3; s := 5.2; QCCumSumChart(data,s,k,h,m,s,sh,sl); // find point indexes which exceed h (out-of-control points) outofcontrol.FindIndexes(shigh,'>',h); end;
#include "MtxVecCpp.h" #include "StatControlCharts.hpp" void __fastcall Example(); { Matrix data; data->LoadFromFile("process_data.mtx"); Vector sh,sl,s,outofcontrol; // estimate k=0.32, h = 4.7 double k = 0.32; double h = 4.7; // estimate process mean and sigma double m = 230.3; double s = 5.2; QCCumSumChart(data,s,k,h,m,s,sh,sl); // find point indexes which exceed h (out-of-control points) outofcontrol->FindIndexes(shigh,">",h); }
using Dew.Math; using Dew.Math.Units; using Dew.Stats.Units; namespace Dew.Examples { private void Example() { Matrix data = new Matrix(0,0); data.LoadFromFile("process_data.mtx"); Vector sh = new Vector(0); Vector sl = new Vector(0); Vector s = new Vector(0); Vector outofcontrol = new Vector(0); // estimate k=0.32, h = 4.7 double k = 0.32; double h = 4.7; // estimate process mean and sigma double m = 230.3; double s = 5.2; StatControlCharts.QCCumSumChart(data,s,k,h,m,s,sh,sl); // find point indexes which exceed h (out-of-control points) outofcontrol.FindIndexes(shigh,">",h); } }

Copyright 2008 Dew Research
http://www.dewresearch.com