Solved – IQR is 0 but mean is not 0

descriptive statisticsinterquartile

I have a dataset where the 5 number summary is:

      Min.    1st Qu.     Median       Mean    3rd Qu.       Max. 
-0.0082630  0.0000000  0.0000000  0.0000059  0.0000000  0.7966557 

I'm not quite sure how to visualize this/whether this is even possible! It is saying that the IQR is 0, while the average value is not 0?

Best Answer

The IQR is a measure of spread and is not related to the mean. You can have any mean with any IQR. It's not clear what relationship you expect there to be.

To see this, start by making a data set with the IQR you want; for example you can get an IQR of 0 by making a lot of values (just over half will do) in the middle of your data set the same, like so:

  1  2  3  5  5  5  5  5  5  5  7  8  9

(13 values, 7 of them equal and in the middle; in this case the mean is 5)

Now add any number you choose to all the values. Say 98. Now the numbers are

 99 100 101 103 103  103  103  103  103  103  105 106 107

The IQR is still 0 but the mean is now 103 (the 5 we started with + the 98 we added).