In (most of) the analytical chemistry literature, the standard test for detecting outliers in univariate data (e.g. a sequence of measurements of some parameter) is Dixon's Q test. Invariably, all the procedures listed in the textbooks have you compute some quantity from the data to be compared with a tabular value. By hand, this is not much of a concern; however I am planning to write a computer program for Dixon Q, and just caching values strikes me as inelegant. Which brings me to my first question:

  1. How are the tabular values for Dixon Q generated?

Now, I have already looked into this article, but I'm of the feeling that this is a bit of cheating, in that the author merely constructs a spline that passes through the tabular values generated by Dixon. I have the feeling that a special function (e.g. error function or incomplete beta/gamma) will be needed somewhere, but at least I have algorithms for those.

Now for my second question: ISO seems to be slowly recommending Grubbs's test over Dixon Q nowadays, but judging from the textbooks it has yet to catch on. This on the other hand was relatively easy to implement since it only involves computing the inverse of the CDF of Student t. Now for my second question:

  1. Why would I want to use Grubbs's instead of Dixon's?

On the obvious front in my case, the algorithm is "neater", but I suspect there are deeper reasons. Can anyone care to enlighten me?


Really, these approaches have not been actively developed for a very long time. For univariate Outliers, the optimal (most efficent) filter is median+/-$\delta \times$ MAD, or better yet (if you have access to R) median+/-$\delta \times$ Qn (so you don't assume the underlying distribution to be symmetric),

The Qn estimator is implemented in package robustbase.


Rousseeuw, P.J. and Croux, C. (1993) Alternatives to the Median Absolute Deviation, Journal of the American Statistical Association *88*, 1273-1283.

Response to comment:

Two levels.

A) Philosophical.

Both the Dixon and Grub tests are only able to detect a particular type of (isolated, single) outlier. For the last 20-30 years the concept of outliers has involved unto "any observation that departs from the main body of the data". Without further specification of what the particular departure is. This characterization-free approach renders the idea of building tests to detect outliers void. The emphasize shifted to the concept of estimators (a classical example of which is the median) that retain there values (i.e. are insensitive) even for large rate of contamination by outliers -such estimator is then said to be robust- and the question of detecting outliers becomes void.

B) Weakness,

You can see that the Grub and Dixon tests easily break down: one can easily generated contaminated data that would pass either test like a bliss (i.e. without breaking the null). This is particularly obvious in the Grubb test, because outliers will break down the mean and s.d. used in the construction of the test stat. It's less obvious in the Dixon, until one learns that order statistics are not robust to outliers either.

I think you will find more explanation of these facts in papers oriented towards the general non-statistician audience such as the one cited above (I can also think of the Fast-Mcd paper by Rousseeuw). If you consult any recent book/intro to robust analysis, you will notice that neither Grubb nor Dixon are mentioned.

  • $\begingroup$ Interesting... I guess analytical chemists are very much behind the times! Mind telling me how both of these became discredited? I will look into your reference and see how the algorithms for these look like. $\endgroup$ Aug 20 '10 at 13:31
  • 3
    $\begingroup$ I see no reason to say that these test have been discredited. If you are trying to detect a single outlier when the population distribution (without the outlier) normal. In fact Grubbs' test satisfies some optimality property. There are always problems with outlier tests such as the masking effect when there are multiple outliers but that does not discredit the methods! The robustness methods use all the data and downweight the outliers so that the outliers will not unduly influence the estimation. $\endgroup$ May 10 '12 at 21:57
  • 1
    $\begingroup$ If you want to learn more about Dixon's test see my other posts on this site regarding questions on outliers and my 1982 paper "On the Robustness of Dixon's ratio Test in Small Samples." $\endgroup$ May 10 '12 at 21:59
  • 1
    $\begingroup$ I guess people must not think I am an expert on outliers because i believe Dixon's test is not discredited. I think that those that think dixon's test is discredited probably don't understand what outlier detection and robust estimation is about. $\endgroup$ May 10 '12 at 22:02
  • 1
    $\begingroup$ @user603 Yes. The first sentence in your post looks so much better! now I am more inclined to listen to your argument which is sensible. I was so turned off by that first sentence that I didn't read the rest of it at first. $\endgroup$ May 11 '12 at 9:43

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.