Why Quantiles Need a Convention
A quantile describes a location in a distribution, but for a discrete distribution there may be a jump across the probability level of interest. There can also be an interval of values on which the CDF is exactly at that level. Consequently, the phrase “the \(u\)-quantile” needs a convention. Once that convention is fixed, a monotone transformation carries quantiles in a predictable way: an increasing map preserves their order, while a decreasing map reverses it.
The distinction matters in practice. A decreasing transformation does not simply send the lower \(u\)-quantile to the lower \(u\)-quantile. It reverses the tail being described, and for distributions with atoms the lower and upper quantile conventions can give different answers.
The lower quantile uses the first threshold at which the CDF is at least \(u\). The upper quantile uses the infimum of the locations at which it is strictly greater than \(u\). For a continuous strictly increasing CDF, these definitions agree. At a jump, or across a flat portion of the CDF, they need not.
Increasing Bijections Preserve Quantile Order
Suppose \(g:I\to J\) is a strictly increasing bijection between intervals, \(P(X\in I)=1\), and \(Y=g(X)\). For \(y\in J\), the inverse \(g^{-1}(y)\) exists and the event \(Y\le y\) is the event \(X\le g^{-1}(y)\). Thus
The quantile identities below use quantile levels \(0<u<1\). In this setting the quantiles lie in the respective intervals \(I\) and \(J\); values outside \(J\) must still be accounted for when identifying an infimum over all real \(y\).
For either choice of threshold, the sets inside the quantile definitions correspond under \(g\) for \(y\in J\): \(F_Y(y)\ge u\) exactly when \(F_X(g^{-1}(y))\ge u\), and the same equivalence holds with \(>\) in place of \(\ge\). Because \(g\) is increasing, it preserves the order of those locations. If \(y\notin J\), then \(Y\in J\) almost surely. A point below the interval \(J\) has \(F_Y(y)=0\), and a point above \(J\) has \(F_Y(y)=1\). Neither kind of point changes the infimum of the threshold set for \(0<u<1\). Therefore each quantile infimum is the image under \(g\) of the corresponding quantile infimum for \(X\). \(\square\)
Worked Example: An Increasing Affine Transformation
Let \(X\) have an exponential distribution with rate \(2\), so \(F_X(x)=1-e^{-2x}\) for \(x\ge0\), and let \(Y=3X+2\). Find the \(0.25\)-quantile and the median of \(Y\).
For \(0<u<1\), solving \(1-e^{-2x}=u\) gives \(Q_X(u)=-\frac12\ln(1-u)\). This CDF is continuous and strictly increasing on its support, so its lower and upper quantiles agree. The map \(g(x)=3x+2\) is strictly increasing, and hence the quantiles of \(Y\) are obtained by applying \(g\) to those of \(X\).
At \(u=0.25\), $$ Q_Y(0.25)=3\left(-\frac12\ln(0.75)\right)+2 =2-\frac32\ln(0.75) \approx 2.4315. $$
At \(u=0.5\), $$ Q_Y(0.5)=3\left(-\frac12\ln(0.5)\right)+2 =2+\frac32\ln 2 \approx 3.0397. $$
As a check, \(Y\le y\) is equivalent to \(X\le (y-2)/3\) for \(y\ge2\), so \(F_Y(y)=1-\exp[-2(y-2)/3]\). Substituting either calculated quantile into this CDF gives its stated probability level.
Decreasing Bijections Reverse the Quantile Order
For a decreasing bijection, the event defining the transformed CDF reverses direction. Let \(g:I\to J\) be a strictly decreasing bijection between intervals, let \(P(X\in I)=1\), and put \(Y=g(X)\). For \(y\in J\),
where \(F_X(x-)=\lim_{t\uparrow x}F_X(t)=P(X<x)\) is the left limit of the CDF. The left limit is essential: an atom at \(x\) belongs to the event \(X\ge x\), not to \(X<x\).
Here is a set-based proof that also checks the points outside the range \(J\). For any CDF \(F_X\) and any \(0<v<1\), $$ \sup\{x:F_X(x-)\le v\}=Q_X^+(v), \qquad \sup\{x:F_X(x-)<v\}=Q_X^-(v). $$ To verify the first identity, write \(q=Q_X^+(v)\). If \(x<q\), then \(F_X(t)\le v\) for every \(t<x\), so \(F_X(x-)\le v\). If \(x>q\), the definition of the infimum gives some \(t<x\) with \(F_X(t)>v\); hence \(F_X(x-)\ge F_X(t)>v\). The supremum of the set is therefore \(q\). For the second identity, write \(r=Q_X^-(v)\). If \(x<r\), then \(F_X(x)<v\), since otherwise \(x\) would belong to the set whose infimum is \(r\). Monotonicity gives \(F_X(x-)\le F_X(x)<v\). If \(x>r\), some \(t<x\) has \(F_X(t)\ge v\), so \(F_X(x-)\ge v\). Thus this set has supremum \(r\). \(\square\)
Set \(v=1-u\). For \(y\in J\), write \(y=g(x)\). The transformed-CDF formula shows that \(F_Y(y)\ge u\) exactly when \(F_X(x-)\le v\); it shows that \(F_Y(y)>u\) exactly when \(F_X(x-)<v\). Since \(g\) is decreasing, the infimum of the corresponding \(y\)-locations is \(g\) applied to the supremum of the \(x\)-locations. If \(y\notin J\) and \(y<g(q)\), where \(q\) is the relevant quantile in \(I\), then \(y\) lies below \(J\): because \(J\) is an interval and \(g(q)\in J\), a point outside \(J\) below \(g(q)\) cannot lie above \(J\). As \(Y\in J\) almost surely, \(F_Y(y)=0<u\). Such points do not lower the infimum. Points above \(J\) have \(F_Y(y)=1\) and cannot lower it either. This proves both identities. \(\square\)
Worked Example: A Decreasing Transformation of an Exponential Variable
Let \(X\) have an exponential distribution with rate \(1\), and set \(Y=1/X\). The map \(g(x)=1/x\) is a strictly decreasing bijection from \((0,\infty)\) to \((0,\infty)\). Find the lower \(0.8\)-quantile of \(Y\).
The exponential CDF is continuous and strictly increasing on its support, so its two quantile conventions agree. Solving \(1-e^{-x}=u\) gives \(Q_X(u)=-\ln(1-u)\). The decreasing-transformation identity uses the complementary level \(1-u=0.2\): $$ Q_Y^-(0.8)=\frac{1}{Q_X(0.2)} =\frac{1}{-\ln(0.8)} \approx \frac{1}{0.22314355} \approx 4.4814. $$
Check directly: for \(y>0\), \(Y\le y\) is equivalent to \(X\ge1/y\). Therefore \(F_Y(y)=P(X\ge1/y)=e^{-1/y}\), and $$ F_Y(4.4814)\approx e^{-0.22314}=0.8. $$ The high quantile of \(Y\) corresponds to a low quantile of \(X\), because taking a reciprocal reverses order.
Worked Example: Why the Two Conventions Matter for Atoms
Suppose \(X\) equals \(0\) and \(1\), each with probability \(1/2\), and let \(Y=-X\). Compute both \(0.5\)-quantiles under each convention.
For \(X\), the CDF is \(0\) below \(0\), \(1/2\) on \([0,1)\), and \(1\) on \([1,\infty)\). Thus $$ Q_X^-(0.5)=0,\qquad Q_X^+(0.5)=1. $$ For \(Y\), the values are \(-1\) and \(0\), each with probability \(1/2\). Its CDF is \(0\) below \(-1\), \(1/2\) on \([-1,0)\), and \(1\) on \([0,\infty)\), giving $$ Q_Y^-(0.5)=-1,\qquad Q_Y^+(0.5)=0. $$
The decreasing identities agree with these calculations: $$ Q_Y^-(0.5)=-Q_X^+(0.5)=-1, \qquad Q_Y^+(0.5)=-Q_X^-(0.5)=0. $$ The two answers differ because the CDF has a flat stretch at height \(1/2\); using only the phrase “the median” would conceal which convention is intended.
Common Mistakes and Practical Use
- Using the same quantile convention after a decreasing map. The lower quantile of \(Y\) is obtained from the upper quantile of \(X\) at level \(1-u\), not generally from the lower \(u\)-quantile of \(X\).
- Replacing \(>\) by \(\ge\) without checking for atoms. In the two-point example, this changes the \(0.5\)-quantile from \(1\) to \(0\) for \(X\).
- Assuming the infimum has to belong to the set. For the upper quantile, the infimum of locations where \(F_X(x)>u\) need not itself satisfy \(F_X(x)>u\). A continuous strictly increasing CDF has \(F_X(Q_X^+(u))=u\).
- Applying an inverse outside its domain. In a proof using \(g^{-1}(y)\), first restrict to \(y\in J\). Points outside the image interval must be handled using \(Y\in J\) almost surely and the CDF values below or above \(J\).
Quantile transformations are useful for reporting percentiles on a changed measurement scale. For an increasing conversion, such as converting a positive measurement to a larger unit, the quantile level is unchanged. For a decreasing score or reciprocal, the level is complemented and the lower and upper conventions switch. These identities can also provide a direct check on a transformed-distribution calculation.
Check Your Understanding
Use the stated lower and upper quantile definitions, especially when the distribution has atoms.
- For a continuous strictly increasing CDF, why do the lower and upper quantiles agree?
- If \(Y=5-X\), express \(Q_Y^-(u)\) and \(Q_Y^+(u)\) in terms of the quantiles of \(X\).
- A random variable takes the values \(2\) and \(6\), each with probability \(1/2\). Find its lower and upper \(0.5\)-quantiles.
- For \(X\) exponential with rate \(1\) and \(Y=1/X\), write the lower \(0.9\)-quantile of \(Y\) in terms of a quantile of \(X\).
- Why must a proof using \(g^{-1}(y)\) distinguish \(y\) inside the image interval from \(y\) outside it?