What is the difference between the three terms below?
- percentile
- quantile
- quartile
Cross Validated is a question and answer site for people interested in statistics, machine learning, data analysis, data mining, and data visualization. It only takes a minute to sign up.
Sign up to join this communityWhat is the difference between the three terms below?
0 quartile = 0 quantile = 0 percentile
1 quartile = 0.25 quantile = 25 percentile
2 quartile = .5 quantile = 50 percentile (median)
3 quartile = .75 quantile = 75 percentile
4 quartile = 1 quantile = 100 percentile
Percentiles go from $0$ to $100$.
Quartiles go from $1$ to $4$ (or $0$ to $4$).
Quantiles can go from anything to anything.
Percentiles and quartiles are examples of quantiles.
percentile(array, 0.5)
(the median)?
$\endgroup$
Jun 23, 2015 at 0:50
In order to define these terms rigorously, it is helpful to first define the quantile function which is also known as the inverse cumulative distribution function. Recall that for a random variable $X$, the cumulative distribution function $F_X$ is defined by the equation $$ F_X(x) := \Pr(X \le x). $$ The quantile function is defined by the equation $$ Q(p)\,=\,\inf\left\{ x\in \mathbb{R} : p \le F(x) \right\}. $$
Now that we have got these definitions out of the way, we can define the terms:
percentile: a measure used in statistics indicating the value below which a given percentage of observations in a group of observations fall.
Example: the 20th percentile of $X$ is the value $Q_X(0.20)$
quantile: values taken from regular intervals of the quantile function of a random variable. For instance, for some integer $k \geq 2$, the $k$-quartiles are defined as the values i.e. $Q_X(j/k)$ for $j = 1, 2, \ldots, k - 1$.
Example: the 5-quantiles of $X$ are the values $Q_X(0.2), Q_X(0.4), Q_X(0.6), Q_X(0.8)$
It may be helpful for you to work out an example of what these definitions mean when say $X \sim U[0,100]$, i.e. $X$ is uniformly distributed from 0 to 100.
References from Wikipedia:
From wiki page: https://en.wikipedia.org/wiki/Quantile
Some q-quantiles have special names:
The only 2-quantile is called the median The 3-quantiles are called tertiles or terciles → T The 4-quantiles are called quartiles → Q The 5-quantiles are called quintiles → QU The 6-quantiles are called sextiles → S The 8-quantiles are called octiles → O (as added by @NickCox - now on wiki page also) The 10-quantiles are called deciles → D The 12-quantiles are called duodeciles → Dd The 20-quantiles are called vigintiles → V The 100-quantiles are called percentiles → P The 1000-quantiles are called permilles → Pr
The difference between quantile
, quartile
and percentile
becomes obvious.