Wednesday, January 28

An Example

I wrote about Hypothesis testing techniques for data that don't fit to any distribution which is called distribution-free or non-parametric. As this is a very useful technique I give u an example of Kruskal-wallis one-way Analysis of Variance by Ranks. it might help u to organize your QC plans:
Suppose u have 3 machines in a workshop, producing the same part. You are concerned with the process consistency and wanna know whether or not the machines produce the part with the same specification. As this is a mass-production, it's definitely not economic to check every single piece and also it's very time-consuming. The other thing is u r not sure if your process fits normal distribution and may think it's a non-normal one. Therefore what u do is u take small samples from each machine and formulate null and alternative hypothesis. Here r the samples from each machine and hypothesis:

the next step is to code the samples and rank them as follows:

After ranking the samples, you calculate the test statistic, H:

The calculated test statistic is compared to critical Chi-square with a degree of freedom of 2. (DF=k[number of sample test]-1. According to Chisquare table (which u can find in any statistics textbook) the critical Chi-square is 5.99 and as the calculated one is less than it, the null hypothesis is not rejected and we conclude that all three machines produce the part with the similar specifications.
Note: take a look at Chi-square distribution. It helps you to understand why the null hypothesis is not rejected:

The shaded area is the region that if the test statistic falls in, it's considered rejected. (There's no scale for this diagram)