Locked lesson.
About this lesson
These tests are used when comparing two non-normal data samples. The Levene's Test checks for the variance and the Mann-Whitney checks the median. These tests are both standard tests in Minitab and the lesson will illustrate how to conduct them.
Exercise files
Download this lesson’s related exercise files.
Levene's and Mann-Whitney Exercise.xlsx10.8 KB Levene's and Mann-Whitney Exercise Solution.docx
385.9 KB
Quick reference
Levene's and Mann Whitney Tests
Levene’s Test and Mann-Whitney Test are hypothesis tests used for testing two non-normal data samples. Levene’s Test checks the variance of the data sample and the Mann-Whitney Test checks the medians.
When to use
These tests are used for non-normal data sets. They are appropriate for comparing the two sets to determine if there are statistically significant differences. This helps to identify root cause factors for problems and to demonstrate the impact of implemented solutions.
Instructions
Levene’s Test
Levene’s Test is similar to the F Test or Bartlett’s Test which is used with normal data. The variance, or spread, of two sets of sample data are compared to determine if they are statistically different. The test can be set to check for equality, greater than or less than relationships. The form of the hypothesis test is:
H0: σ12 = σ22
Ha: σ12 ≠ σ22
- Minitab:
- Stat > Basic Statistics > 2 Variances
- Select the columns with the data, the order matters if doing a greater than or less than relationship.
- Use the Option button to change the type of relationship to be tested – default is equal/not equal.
- Use the Option button to ensure that the normality box is not checked (checking the box will result in an F Test instead of Levene’s Test).
Mann-Whitney Test
The Mann-Whitney Test is similar to the Two-Sample T Test used with normal data. The primary difference is that Mann-Whitney uses the median value since it is the preferred measure for central tendency with non-normal data. The test can be to check for equal medians or to check whether one is greater than or less than the other. The form of the hypothesis test is:
H0: median1 – median2 = 0
Ha: median1 > median2 or Ha: median1 < median2
- Minitab:
- Stat > Nonparametrics > Mann Whitney
- Select the format of the data
- Select the columns with the data
- Select the relationship to be tested (equals, greater than, less than)
- The results are shown in the Session Window. Minitab states that “the test is significant at .XXX” This is the P Value for the test.
Hints & tips
- The Levene’s Test provides a box plot that makes the differences between the data samples very clear.
- Check your data for normality first. If normal, use the F Test and Two-Sample T Test, if non-normal, use these tests.
- A small number of data points has a tendency to result in variances and medians with large confidence intervals. This makes it more difficult to identify true differences.
- 00:04 Hi, I am Ray Sheen, and let's stick with non-normal data.
- 00:08 Now, let's look at what to do when there's two sample sets.
- 00:12 The Levene's test and the Mann-Whitney test,
- 00:16 can determine if they are truly different.
- 00:19 Going back into the hypothesis test decision tree, we see that we're working
- 00:23 with data samples that are non-normal, and that there are two sets of them.
- 00:28 The best approach is to use the Levene's test for variance,
- 00:32 followed by the Mann-Whitney test.
- 00:34 The Levene's test is for variances.
- 00:37 Levene's test is similar to the F-test or Bartlett's test, except that it's less
- 00:42 sensitive, and therefore, is better suited to non-normal data.
- 00:45 Levene's test will determine if the variances for
- 00:49 two non-normal data sets are statistically equal or statistically different.
- 00:54 Minitab will do this test at the same time that it does the F-test for normal data.
- 00:59 You may recall that when we did that, the way was to select the Stat pulldown menu,
- 01:05 then select Basic Statistics, and then select 2 Variances.
- 01:09 Ensure that the box for normal data on the option panel is not checked.
- 01:14 This is the default value, but if you've been doing F-tests and check that box,
- 01:18 it may still be checked when you attempt to do this test.
- 01:22 The hypotheses are similar to the F-tests and Bartlett's test.
- 01:25 The null hypothesis is that the variance for each sample are equal,
- 01:30 and that the alternative hypothesis is that the variances are not equal.
- 01:34 If your Lean Six Sigma problem was to reduce variation in the process with
- 01:39 non-normal results, then the Levene's test is the appropriate test to use.
- 01:44 Now let's consider the Mann-Whitney test.
- 01:47 The Mann-Whitney test is a non-parametric test that considers whether the medians
- 01:52 from two samples are statistically different.
- 01:55 The samples do not need to be normally distributed, nor
- 01:58 do they need to have equal variance.
- 02:01 This test is similar to the 2 Sample T-test for normal data,
- 02:05 only the T-test uses mean values, and this test uses the median values,
- 02:10 since this is a more appropriate measure for non-normal data.
- 02:14 A common use of this test is to determine if the median value of non-normal process
- 02:19 parameters has changed following the implementation of an improvement in
- 02:23 the process.
- 02:24 It can also be used to analyze problems in the same way that the T-test is used to
- 02:29 determine when two samples should be considered to be from the same
- 02:33 population or from different populations.
- 02:36 The results are often a confidence interval when the medians are the same.
- 02:40 The session window in Minitab will show us the results.
- 02:44 The null hypothesis is that the median for the two samples is statistically equal,
- 02:49 and the alternative hypothesis is normally that one is greater or
- 02:53 less than the other.
- 02:54 The Mann-Whitney test in Minitab is easy to conduct, but
- 02:57 there are some minor points of difference in the results that are presented.
- 03:01 Conduct the test in Minitab following our now familiar process.
- 03:05 Select the pulldown menu Stat, then select the Non-parametric, and
- 03:09 select Mann-Whitney.
- 03:11 This panel will appear.
- 03:12 Then enter your column, and enter the alternative hypotheses operator.
- 03:17 One point to note,
- 03:18 you don't need to tell Mann-Whitney whether the variances are equal or not.
- 03:23 From our standpoint in the hypothesis testing, Levene's test is the stand-alone
- 03:27 test for variance, and Mann-Whitney is a stand-alone test for medians.
- 03:32 Minitab will provide results in the session window, but
- 03:35 here's the point that's a little bit squirrely.
- 03:37 Minitab does not state a p value, instead,
- 03:40 it says that this is significant at a calculated value.
- 03:45 For our purposes,
- 03:46 we will use that calculated value in the same way as we would a p value.
- 03:50 So in this case, the test value is 0.4968.
- 03:55 And we would then fail to reject the null hypothesis.
- 03:58 The median values from Time 1 and Time 2 are statistically equal.
- 04:04 However, when we look at the median values from Times 1 and
- 04:08 Times 3, we get a different answer.
- 04:10 In this case, the test is significant at 0.0010.
- 04:15 This is far below our p-value threshold of 0.05, so we reject the null hypothesis.
- 04:21 For this case, the medians for Time 1 and Time 3 are not statistically equal.
- 04:27 The Levene's test and Mann-Whitney test do for non-normal data,
- 04:31 what you use the F-test and the T-test for with normal data.
- 04:35 If your data is not normal, you'll probably be using these tests quite a bit.
Lesson notes are only available for subscribers.
PMI, PMP, CAPM and PMBOK are registered marks of the Project Management Institute, Inc.