# Interquartile range

I have grouped data ranges that I need to find the interquartile range for, I think i have found the groups that the upper and lower quartiles are in, but as they are ranged, where do I go from here? Do I find the mid point of each range and then subtract them like you normally would or am I completely off track?

Also could someone possible explain the difference between the interquartile range and the semi interquartile range please?

Any help anyone could give me would be greatly appreciated.

Many thanks :)

-

The best thing to do would be to go back to the ungrouped raw data and calculate the upper and lower quartiles from there. If you cannot do that then you need to interpolate withing the groups.

You should not take the difference between the midpoints of the ranges. Instead, it would be better to see how much of each of the relevant groups in within the interquartile range.

For example, if 35% of the upper group is in the interquartile range then you could take the point 35% of the way from its lower boundary to its upper boundary. Similarly if 30% of the lower group is in the interquartile range then you could take the point 30% of the way from its upper boundary to its lower boundary. Then take the difference between these points.

Adding an example, if the groups and frequencies were

   Group    Frequency
0 -  4.99      4
5 -  9.99      5
10 - 14.99     11
15 - 19.99     10
20 +            1


you might decide the lower quartile of the 31 observations was at the 8th observation (fourth of the five in the 5-9.99 group, perhaps 70% of the way up) and the upper quartile at the 24th observation (fourth of the ten in the 15-19.99 group, perhaps 35% of the way up). So you might take the lower quartile to be $5 \times 0.3 + 10 \times 0.7 = 8.5$ and the upper quartile to be $15 \times 0.65 + 20 \times 0.35 = 16.75$. So the interquartile range might be $16.75-8.5 = 8.25$.

Becoming more sophisticated, you might decide not to assume that there is a uniform distribution in each group, and instead choose a density which takes into account frequencies in neighbouring groups. At this stage it is probably easier to get a computer to do the calculations. There is more than one way to do it, and Wikipedia has a description of some of the different ways of estimating the quantiles of a population

-
Hi Henry, thanks for your answer, unfortunately I do not have access to the raw data so by the sounds of it I need to Interpolate within the groups, could you please explain what this means? And also, could you pelase explain the difference between semi interquartile range and interquartile range please? – Jamie Jun 12 '11 at 13:10
@Jamie: I have added a worked example – Henry Jun 12 '11 at 13:34
OK that makes sense, i think thats the way Ill do it, many thanks for your help! :) – Jamie Jun 12 '11 at 14:31