Tutorials › Generalized Linear Models › Reversing the Order of Response Categories

Cumulative Link Models · Tutorial 547 of 981

Reversing the Order of Response Categories

Learn to transform a cumulative-link model under reversed response ordering and check that the transformed model assigns the same probabilities to the correspondingly relabeled outcomes.

Intermediate 10 min read

What You'll Learn

  • Express reversed cumulative events using the original response categories.
  • Transform ordered thresholds and regression coefficients under reversal.
  • Verify probability equivalence for binary, three-category, and four-category models.
  • Explain why the sign of a coefficient depends on the response ordering.
  • Identify when a reversed model stays within the same link family.

Why Response Order Matters

Ordinal categories have an order, but that order can be recorded in either direction. A rating scale might run from “poor” to “excellent,” or from “excellent” to “poor.” Reversing the labels does not change the underlying observations, yet it changes which outcomes belong to a cumulative event such as “at or below category \(j\).” As a result, the model’s thresholds and coefficient signs must change in a coordinated way if the fitted probabilities are to remain the same.

We use the cumulative-link convention established for this course. For a response \(Y\) with ordered categories \(1,\ldots,K\), covariate vector \(x\), thresholds \(\theta_1<\cdots<\theta_{K-1}\), coefficient vector \(\beta\), and link CDF \(F\), the model is

$$ P(Y\leq j\mid x)=F(\theta_j-x^\mathsf{T}\beta), \qquad j=1,\ldots,K-1. $$

For the logit and probit links, \(F\) is symmetric about zero: \(1-F(u)=F(-u)\). This symmetry is what allows reversal to be written using the same link and a simple sign change. We will use that property explicitly rather than assume it holds for every possible link function.

Definition: Reversing the order of a \(K\)-category response replaces \(Y\) by \(Z=K+1-Y\). Thus old category \(K\) becomes new category 1, old category \(K-1\) becomes new category 2, and so on. The observations themselves are unchanged; only their ordered labels are reversed.

Transforming Cumulative Events, Thresholds, and Slopes

The event \(Z\leq j\) means that the original response was among its highest \(j\) categories. Equivalently, \(Y\geq K+1-j\). Its complement is \(Y\leq K-j\), so the original cumulative probabilities determine the reversed cumulative probabilities.

Theorem: Suppose \(Y\) follows the cumulative-link model above and \(F\) satisfies \(1-F(u)=F(-u)\). For the reversed response \(Z=K+1-Y\), the same link family gives $$ P(Z\leq j\mid x)=F(\theta^{R}_j-x^\mathsf{T}\beta^{R}), \qquad \theta^{R}_j=-\theta_{K-j},\quad \beta^{R}=-\beta, \qquad j=1,\ldots,K-1. $$ The reversed thresholds are ordered, and the category probabilities for \(Z\) are the original category probabilities in reverse order.

Proof. For \(j=1,\ldots,K-1\), the definitions of \(Z\) and a cumulative event give

$$ \begin{aligned} P(Z\leq j\mid x) &=P(Y\geq K+1-j\mid x)\\ &=1-P(Y\leq K-j\mid x)\\ &=1-F(\theta_{K-j}-x^\mathsf{T}\beta)\\ &=F(x^\mathsf{T}\beta-\theta_{K-j})\\ &=F\bigl(-\theta_{K-j}-x^\mathsf{T}(-\beta)\bigr). \end{aligned} $$

This is the cumulative-link form with \(\theta^{R}_j=-\theta_{K-j}\) and \(\beta^{R}=-\beta\). Since the original thresholds increase, \(\theta_{K-j}\) decreases as \(j\) increases. Negating these values therefore produces an increasing sequence: \(\theta^{R}_1<\cdots<\theta^{R}_{K-1}\).

To verify the category probabilities, define the cumulative probabilities at the endpoints as \(P(Y\leq0\mid x)=0\) and \(P(Y\leq K\mid x)=1\). A category probability is the difference between adjacent cumulative probabilities. The reversed category \(j\) is exactly the original category \(K+1-j\), so

$$ P(Z=j\mid x)=P(Y=K+1-j\mid x). $$

Thus the probabilities are preserved for the relabeled outcomes, in reverse order. The threshold transformation also preserves the model’s admissible ordering, so it defines a valid cumulative-link model. \(\square\)

Worked Examples

Worked Example: Reversing a Binary Response

Suppose \(Y\) has categories 1 and 2, and

$$ P(Y\leq1\mid x)=\operatorname{logit}^{-1}(0.7-1.2x). $$

At \(x=0.5\), the cumulative linear predictor is \(0.7-1.2(0.5)=0.1\), so

$$ P(Y=1\mid x=0.5)=\frac{1}{1+e^{-0.1}}=0.5249792, \qquad P(Y=2\mid x=0.5)=1-0.5249792=0.4750208. $$

After reversal, \(Z=3-Y\), and the transformed threshold and coefficient are \(\theta^{R}_1=-0.7\) and \(\beta^{R}=-1.2\). The reversed model gives

$$ P(Z\leq1\mid x=0.5) =\operatorname{logit}^{-1}(-0.7-(-1.2)(0.5)) =\operatorname{logit}^{-1}(-0.1) =0.4750208. $$

This is \(P(Y=2\mid x=0.5)\), as required: new category 1 is old category 2. The remaining probability is \(P(Z=2\mid x=0.5)=0.5249792=P(Y=1\mid x=0.5)\). The slope changes sign because increasing \(x\) shifts probability toward the higher original category, which is the lower category after reversal.

Worked Example: Reversing a Three-Category Ordinal Response

Let \(Y\in\{1,2,3\}\) follow a cumulative logit model with thresholds \(\theta_1=-0.7\), \(\theta_2=1.3\), and coefficient \(\beta=1\). The thresholds are ordered because \(-0.7<1.3\). At \(x=1\), the two cumulative linear predictors are \(-0.7-1=-1.7\) and \(1.3-1=0.3\). Therefore,

$$ \begin{aligned} P(Y\leq1\mid x=1)&=\operatorname{logit}^{-1}(-1.7)=0.1544653,\\ P(Y\leq2\mid x=1)&=\operatorname{logit}^{-1}(0.3)=0.5744425. \end{aligned} $$

Differencing the unrounded cumulative probabilities gives the category probabilities:

$$ \begin{aligned} P(Y=1\mid x=1)&=0.1544653,\\ P(Y=2\mid x=1)&=\operatorname{logit}^{-1}(0.3)-\operatorname{logit}^{-1}(-1.7) \approx 0.4199773,\\ P(Y=3\mid x=1)&=1-\operatorname{logit}^{-1}(0.3) \approx 0.4255575. \end{aligned} $$

The probabilities sum to \(0.1544653+0.4199773+0.4255575=1.0000001\), with the excess \(0.0000001\) due only to rounding. For the reversed response \(Z=4-Y\), the thresholds are \(\theta^{R}_1=-1.3\), \(\theta^{R}_2=0.7\), and the coefficient is \(\beta^{R}=-1\). At \(x=1\), the reversed cumulative predictors are \(-1.3-(-1)= -0.3\) and \(0.7-(-1)=1.7\). Hence

$$ \begin{aligned} P(Z\leq1\mid x=1)&=\operatorname{logit}^{-1}(-0.3)=0.4255575,\\ P(Z\leq2\mid x=1)&=\operatorname{logit}^{-1}(1.7)=0.8455347. \end{aligned} $$

Differencing the unrounded reversed cumulative probabilities yields

$$ \begin{aligned} P(Z=1\mid x=1)&=0.4255575,\\ P(Z=2\mid x=1)&=\operatorname{logit}^{-1}(1.7)-\operatorname{logit}^{-1}(-0.3) \approx 0.4199773,\\ P(Z=3\mid x=1)&=1-\operatorname{logit}^{-1}(1.7) \approx 0.1544653. \end{aligned} $$

The result is the original vector read backward: category 1 of \(Z\) corresponds to category 3 of \(Y\), category 2 corresponds to itself, and category 3 corresponds to category 1. The middle probability is obtained from the unrounded cumulative probabilities; subtracting displayed, rounded cumulative values can produce a different last decimal place.

Worked Example: Checking a Four-Category Reversal

Consider a cumulative logit model with thresholds \((-1,0.5,1.4)\), coefficient \(\beta=0.6\), and \(x=0.5\). The quantity \(x\beta\) is \(0.3\), so the cumulative predictors are \((-1.3,0.2,1.1)\). Their logistic CDF values are approximately \((0.2141650,0.5498340,0.7502601)\). Differencing gives

$$ \begin{aligned} (P(Y=1),P(Y=2),P(Y=3),P(Y=4)\mid x=0.5) &\approx(0.2141650,\ 0.3356690,\ 0.2004261,\ 0.2497399). \end{aligned} $$

The transformed thresholds are \((-1.4,-0.5,1)\), and the transformed coefficient is \(-0.6\). With \(x=0.5\), the reversed cumulative predictors are \((-1.1,-0.2,1.3)\), giving cumulative probabilities approximately \((0.2497399,0.4501660,0.7858350)\). Differencing produces

$$ (P(Z=1),P(Z=2),P(Z=3),P(Z=4)\mid x=0.5) \approx(0.2497399,\ 0.2004261,\ 0.3356690,\ 0.2141650). $$

This is precisely the first vector in reverse order. Each displayed value is rounded to seven decimal places, so sums calculated from displayed values can differ from one by a final rounding unit.

What the Sign Change Means

A coefficient’s sign is tied to the direction in which categories are ordered. Under the convention \(P(Y\leq j\mid x)=F(\theta_j-x^\mathsf{T}\beta)\), a positive coefficient for a scalar predictor lowers the cumulative probability of being at or below any fixed threshold as that predictor increases. In this sense it shifts probability toward higher categories. After reversing the order, those same outcomes are lower categories, and the equivalent coefficient is negative.

This sign change does not indicate that the data support a different relationship. It is a consequence of the response coding. When comparing coefficients from analyses with different category orderings, first check how each model defines its cumulative event and linear predictor. The sign alone is not interpretable without that convention.

The threshold transformation matters as much as the slope transformation. Reversing only the coefficient, while leaving the thresholds unchanged, will generally change the fitted cumulative probabilities. Conversely, thresholds become \(-\theta_{K-j}\), not simply the negatives in their original order: reversing their indices is necessary to keep the transformed thresholds increasing.

Likelihood Equivalence Under Relabeling

For independent observations with fixed covariates, the transformation preserves the likelihood when the response labels and parameters are both reversed. To see this, write \(p_{ik}(\theta,\beta)=P(Y_i=k\mid x_i)\) for observation \(i\). The probability result above states that the reversed model’s probability for category \(K+1-k\) is \(p_{ik}(\theta,\beta)\). If the observed response is \(y_i\), its reversed label is \(z_i=K+1-y_i\), and therefore

$$ P(Z_i=z_i\mid x_i;\theta^{R},\beta^{R}) = P(Y_i=y_i\mid x_i;\theta,\beta). $$

Multiplying these equalities over independent observations gives the same likelihood value at the corresponding parameter values. The transformation is also reversible: applying it twice restores the original labels, thresholds, and coefficients. Thus reversing all response categories changes the parameter representation, but not the fitted probabilities or the likelihood for the correspondingly relabeled data.

Common Mistake

  • Wrong reasoning: “The categories were reversed, so the coefficient changes sign, but the thresholds stay as they are.” This ignores that each new cumulative event corresponds to the complement of a different old cumulative event.
  • Correction: For every new cutpoint \(j\), use the old cutpoint \(K-j\), take its negative, and reverse the coefficient sign. In symbols, \(\theta^{R}_j=-\theta_{K-j}\) and \(\beta^{R}=-\beta\). Check the transformation by evaluating at least one cumulative probability and then differencing to obtain category probabilities.
  • Also check the convention: If a model is written with a different sign in its linear predictor, the coefficient-sign statement must be translated to that convention. The result above follows from the explicitly stated \(F(\theta_j-x^\mathsf{T}\beta)\) form.
Key takeaway: For a symmetric cumulative-link CDF such as the logistic or standard normal CDF, reversing \(Y\) to \(K+1-Y\) sends each threshold to the negative of the threshold with reversed index and sends \(\beta\) to \(-\beta\). The fitted category probabilities are unchanged apart from being listed in reverse order.

Check Your Understanding

Use the cumulative-link convention stated above when answering.

  1. For five response categories, write the reversed threshold sequence in terms of \(\theta_1,\theta_2,\theta_3,\theta_4\).
  2. Explain why the event \(Z\leq2\) for a reversed five-category response is the complement of an event involving \(Y\).
  3. A binary cumulative logit model has threshold \(0.4\) and coefficient \(-0.8\). What are the equivalent parameters after reversing the response categories?
  4. Why does reversing category order change the coefficient sign without changing the underlying fitted relationship?
  5. What property of the link CDF allows the reversed model to use the same link family with negated thresholds and coefficients?
Clinical Biostats