8
$\begingroup$

I know that if I can have two distributions with the same mean and variance be different shapes, because I can have a N(x,s) and a U(x,s)

But what about if their min, Q1, median, Q3, and max are identical?

Can the distributions look different then, or will they be required to take the same shape?

My only logic behind this is if they have the exact same 5-number summary they must take on the exact same distribution shape.

$\endgroup$
  • 1
    $\begingroup$ The answer to this question is in some senses obvious - if we could completely chararacterise any distribution simply by quoting five numbers about it, then all those exams on probability distributions would be a lot easier! But it raises the interesting point of just how much information is missing when we quote the five-number summary or present the data graphically in a box plot. $\endgroup$ – Silverfish Jan 31 '15 at 2:13
  • 2
    $\begingroup$ Just beware that $U(x,s)$ isn't usually used for the uniform distribution with mean $x$ and standard deviation $s$, but rather for the uniform distribution on the interval that starts at $x$ and ends at $s$. Also the notation $N(x,s)$ is rarely used for the normal distribution (though I've seen some textbooks that do); it's much more common for the second parameter to represent the variance rather than standard deviation. $\endgroup$ – Silverfish Jan 31 '15 at 2:15
17
$\begingroup$

Just because the five-number summary is identical doesn't mean that the distribution is identical. This tells you just how much information is lost when we present data graphically in a box plot!

Perhaps the easiest way to see the problem is that the five number summary tells you nothing about the distribution of the values between the minimum and lower quartile, or between the lower quartile and the median, and so on. You know that the frequency between minimum and lower quartile must match the frequency between lower quartile and median (with the obvious exceptions, e.g. if we have data lying on a quartile, or worse, if two quartiles are tied) but don't know to which values of the variable those frequencies are allocated. We can have a situation like this:

Different distributions with the same five-number summary and box plot

These two distributions have the same five-number summary, so their box plots are identical, but I have chosen $X$ to have a uniform distribution between each quartile whereas $Y$ has a distribution with low frequencies close to the quartiles and high frequencies in the middle of two quartiles. Effectively the distribution of $Y$ has been formed by taking the distribution of $X$ and moving most of the data that is close to a quartile further away from it; my R code actually performs this in reverse, starting with the irregular distribution of $Y$ and levelling out the frequencies by reallocating data from the peaks to fill in the troughs.

EDIT: As @Glen_b says, this becomes even more obvious when you look at the cumulative distributions. I've added gridlines to show the location of the quartiles, which are the same for the two distributions so their empirical CDFs intersect.

Empirical CDFs of two distributions with the same five-number summary

R code

yfreq <- 2*rep(c(1:10, 10:1), times=4)
xfreq <- rep(mean(yfreq), times=length(yfreq))

x <- rep(1:length(xfreq), times=xfreq)
y <- rep(1:length(yfreq), times=yfreq)

ecdfX <- ecdf(x)
ecdfY <- ecdf(y)
plot(ecdfX, verticals=TRUE, do.points=FALSE, col="blue", lwd=2, yaxt="n", 
    main="Empirical CDFs", xlab="", ylab="Relative cumulative frequency")
plot(ecdfY, verticals=TRUE, do.points=FALSE, add=TRUE, col="black",
    yaxt="n", lwd=2)
axis(side=2, at=seq(0, 1, by=0.1), las=2)
abline(h=c(0.25,0.5,0.75,1), col="lightgrey", lty="dashed")
abline(v=summary(x), col="lightgrey", lty="dashed")
legend("right", c("x", "y"), col = c("blue", "black"),
       lty = "solid", lwd=2, bty="n")

par(mfrow=c(2,2))
hist(x, col="steelblue", breaks=((0:81)-0.5), ylim=c(0,25))
hist(y, col="grey", breaks=((0:81)-0.5), ylim=c(0,25))
boxplot(x, col="steelblue", main="Boxplot of x")
boxplot(y, col="grey", main="Boxplot of y")

summary(x)
#   Min. 1st Qu.  Median    Mean 3rd Qu.    Max. 
#   1.00   20.75   40.50   40.50   60.25   80.00 

summary(y)
#   Min. 1st Qu.  Median    Mean 3rd Qu.    Max. 
#   1.00   20.75   40.50   40.50   60.25   80.00 
| cite | improve this answer | |
$\endgroup$
  • 1
    $\begingroup$ +1 Your example is great, because one might initially think: well, certainly a distribution cannot be fully described by five numbers as it is an infinite-dimensional object, but surely all distributions with the same mean/median/quartiles/etc. are at least very similar! Well, no, they are not. By the way, your PDFs show it much more strikingly than the CDFs. $\endgroup$ – amoeba Jan 31 '15 at 22:24
  • 1
    $\begingroup$ @amoeba Thanks, visually the histogram is much more striking. The CDF, I think, shows more clearly what's going on, in the sense of how we might generalise it. $\endgroup$ – Silverfish Jan 31 '15 at 23:42
  • $\begingroup$ @amoeba I am not sure I understand "well, certainly a distribution cannot be fully described by five numbers as it is an infinite-dimensional object" were you writing that as an example of a fallacious idea? For example, the normal PDF is a two-dimensional object (or possibly one or two dimensions more if you want to charge for constants like $\pi$)... quite a bit smaller than infinite! Sorry if I am being obtuse. $\endgroup$ – Alexis Jan 5 '19 at 22:08
  • $\begingroup$ @Alexis I think I meant "an [arbitrary] distribution" in that comment, not a distribution from some particular parametric family... $\endgroup$ – amoeba Jan 5 '19 at 22:39
  • $\begingroup$ @amoeba That's fair. Especially since it was rhetorical use Still, we ought be careful about throwing "infinity" around... I think if someone is really insisting on infinity as part of their system, there's probably arbitrage to be had in a disequilibrium somewhere. :) $\endgroup$ – Alexis Jan 5 '19 at 22:53
15
$\begingroup$

This is most clearly answered by considering the (cumulative) distribution function.

Specifying the minimum, maximum and the three quartiles specifies exactly 5 points on the cdf, but the cdf between those points may be any monotonic nondecreasing function in between that still passes through those points:

enter image description here

In the drawing, both the red and black CDFs share the same minimum, maximum, and quartiles, but are clearly different distributions. Clearly any number of other CDFs could be specified that also pass through the same five points.

In fact, all we've done is restrict our distribution function to lie within four boxes:

$\qquad$enter image description here

(as long as it also continues to satisfy the other conditions for a CDF). That isn't all that much of a restriction.

The same notion can be applied to sample quantities - two different empirical CDFs may nevertheless have the same five-number summary.

| cite | improve this answer | |
$\endgroup$
3
$\begingroup$

No, definitely not the case. As a simple counter example, compare the continuous uniform distribution on $[0, 3]$ with the discrete uniform distribution on $\{0, 1, 2, 3\}$.

A related example is the well-known Anscombe's quartet, where there are 4 datasets with 6 identical sample properties (though different from the ones you mention) look completely different. See: http://en.wikipedia.org/wiki/Anscombe%27s_quartet

| cite | improve this answer | |
$\endgroup$

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.