4
$\begingroup$

Hi math people.

I'm in the process of analyzing some data that I collected through an experiment. The data are (somewhat) normally distributed and I represent the different data-sets using boxplot, to provide an easy way of visually comparing the mean between the data-sets and the change in the variance.

In Matlab as default, the whiskers are used to represent all samples lying within 1.5 times the IQR. According to Wikipedia on the boxplot, this is one of several way of using the whiskers. My question is simple why? What special significance does 1.5 times IQR have? Why not e.g. three times sigma?

(NB: I wanted to add the tags "matlab" and "boxplot", but I'm unable to create new tags.)

$\endgroup$
2
  • $\begingroup$ This won't answer your question, but you should note that you are misusing the word "sample". The whole set of numbers that you've got is your sample; the individual numbers are not samples; they're observations within a sample. It doesn't seem clear what is meant by "within 1.5 times the IQR". Does that mean within that distance of the median? Or the mean? Or maybe of the quartiles? Or what? $\endgroup$ May 30, 2010 at 23:47
  • $\begingroup$ @Michael Thanks for the input. I have always thought of samples as the single "elements" of data you collect e.g. during an experiment or from a signal (as in sampling a signal, which results in a lot of samples from a sampled signal.) So a sample is a set of observations collected through a single trial(?). Do you have a source on this, just so I can get a clear understand of the correct use of the words? $\endgroup$
    – bjarkef
    Jun 1, 2010 at 18:09

2 Answers 2

6
$\begingroup$

Three sigma has less relevance for asymmetric distributions. Using quartiles keeps it nonparametric. Regarding why not other quantiles of the distribution rather than 1.5*IQR, you can follow some comments on this thread, which basically argues that you want to avoid specifying a fixed fraction of your data to be flagged as 'outliers'.

$\endgroup$
6
$\begingroup$

First of all, you should note the difference between statistics and robust statistics. Do not compare the standard deviation (sigma) which is a non robust measure of how the data scatters with the robust IQR.

Second, why 1.5 times the IQR? Since you are a Matlab user, try the following commands :

x = normrnd(0,1,1000000,1);
Q = quantile(x,[0.25 0.5 0.75]);
IQR = Q(3) - Q(1); 
w1 = Q(1) - 1.5 * IQR;
w2 = Q(3) + 1.5 * IQR;
p = normcdf(w2) - normcdf(w1); 

You will see that p is 0.993, so that 99.3% of N(0,1) data are within the whiskers, which is close to 99%. This may be the reason why Tukey chose this.

$\endgroup$

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