Why Include Sample-Level Covariates?
Donors may differ in age, batch, disease severity, or other measured characteristics that are associated with cell-type composition. A model with sample-level covariates describes how the composition varies with condition while holding those covariates fixed. The observations for this analysis are donor-level cell counts, not individual cells treated as independent replicates.
Multinomial logistic regression models all cell types jointly. Its fitted probabilities are nonnegative and sum to one for each covariate profile, so the model respects the fact that the cell-type proportions form a composition. Its coefficients describe changes in relative probabilities, not changes in the total number of cells or absolute abundance in tissue.
Baseline-Category Model and Its Assumptions
Choose one cell type as the reference category; here it is cell type \(K\). Let \(x_i\) be the vector of donor-level covariates, including an intercept. For every non-reference type \(j\), the model specifies a linear predictor \(\eta_{ij}=x_i^\mathsf{T}\beta_j\), where \(\beta_j\) is the coefficient vector for that cell type relative to the reference.
The equivalent probability expressions are
The model is used under several substantive and statistical conditions. Cell types should be mutually exclusive and collectively cover the counts being modeled. Donors are the independent observational units; conditional on each donor's total and covariates, the model uses a multinomial sampling distribution for that donor's counts. The mean log ratios are assumed to be linear in the specified covariates unless transformations or interactions are included. The design must contain enough information to estimate the coefficients: severe collinearity, very sparse categories, or separation can make estimates unstable or infinite. Finally, the multinomial sampling assumption should be plausible. Extra donor-to-donor variation beyond that assumption can make model-based uncertainty too small.
The likelihood makes the role of each donor explicit. Conditional on \(n_i\), donor \(i\)'s count vector has probability proportional to \(\prod_j p_{ij}^{Y_{ij}}\), with the multinomial coefficient accounting for the number of cell label arrangements. Assuming donors are independent, the log likelihood is
The coefficient score has a useful interpretation. For a non-reference category \(j\), differentiating the donor's log likelihood with respect to a coefficient multiplying covariate \(x_{im}\) gives \(x_{im}(Y_{ij}-n_i p_{ij})\). Summing over donors gives
Thus estimation seeks coefficients for which covariate-weighted observed counts and model-expected counts are balanced. This also clarifies why a donor with more cells contributes more to the count likelihood, while remaining one independent donor rather than many independent experimental units.
Fitted Probabilities From a Model
Worked Example: Computing Probabilities for One Donor Profile
Suppose a hypothetical fitted model has three cell types: A, B, and T, with T as the reference. For a specified donor profile, the fitted linear predictors are \(\eta_A=-0.4\) and \(\eta_B=-0.8\). Calculate the fitted probabilities, then the expected counts if that donor has \(n_i=60\) classified cells.
The reference-category denominator is
Therefore,
The probabilities sum to \(0.3162+0.2120+0.4718=1.0000\), subject to rounding. The expected counts are \(60p_A\approx18.97\), \(60p_B\approx12.72\), and \(60p_T\approx28.31\). These are model expectations, not a claim that a donor must have fractional cells.
Interpreting Covariate Coefficients and Contrasts
For a one-unit increase in a covariate, holding the other modeled covariates fixed, \(\beta_{jm}\) is the change in the log ratio \(p_{ij}/p_{iK}\). Exponentiating gives the multiplicative change in that probability ratio. It is not, in general, a multiplicative change in \(p_{ij}\) alone: changing one linear predictor changes the normalized probabilities for all cell types.
For two non-reference cell types \(j\) and \(r\), subtract their reference-category equations:
Consequently, a condition contrast for type \(j\) versus type \(r\) is the difference between their condition coefficients. This is often more informative than interpreting either coefficient in isolation. The selected reference category changes the coefficient representation, but fitted probabilities and contrasts between cell types do not depend on that choice when the model is reparameterized correctly.
Worked Example: An Adjusted Condition Contrast
Suppose a hypothetical model uses T as the reference and includes condition \(C\) (0 for control, 1 for treated) and centered age \(A=\text{age}-50\). Its fitted equations are \(\eta_A=-0.2+0.7C+0.03A\) and \(\eta_B=0.1-0.2C+0.01A\). Interpret the condition effects at fixed age.
For A relative to T, the treated-versus-control log-ratio contrast is \(0.7\), so the ratio \(p_A/p_T\) is multiplied by
For B relative to T, the corresponding multiplier is \(\exp(-0.2)\approx0.8187\). These are adjusted changes in relative probabilities, not direct percentage-point changes in the cell-type proportions.
To compare A directly with B, subtract the two condition coefficients: \(0.7-(-0.2)=0.9\). Thus the ratio \(p_A/p_B\) is multiplied by \(\exp(0.9)\approx2.460\) in treated versus control donors of the same age. This says the A-to-B probability ratio is about 2.46 times as large, under the fitted model.
For a probability illustration at age 50, the control linear predictors are \((-0.2,0.1)\). The unnormalized weights are \((\exp(-0.2),\exp(0.1),1)=(0.8187,1.1052,1)\), with sum \(2.9239\), giving probabilities approximately \((0.2800,0.3780,0.3420)\). For treated donors the predictors are \((0.5,-0.1)\), with weights \((1.6487,0.9048,1)\) and sum \(3.5535\), giving probabilities approximately \((0.4639,0.2546,0.2814)\). These model-based probabilities show why a log-ratio coefficient is not itself a percentage-point change.
Inference and the Distinction From One-Versus-Rest Models
A condition effect can be assessed for one cell type relative to the reference by testing its condition coefficient, or for a pairwise cell-type contrast by testing the relevant difference of coefficients. A global condition test asks whether condition contributes to any of the non-reference log ratios. For a binary condition and \(K\) cell types, the null hypothesis sets all \(K-1\) condition coefficients to zero. A likelihood-ratio test compares the fitted model with condition to a nested model without condition, using twice the difference in maximized log likelihoods; under standard regularity conditions, its reference distribution is chi-squared with \(K-1\) degrees of freedom. This is an association test conditional on the included covariates, not a test of a causal effect.
A separate one-versus-rest regression instead treats each selected cell type as a binary outcome: its count versus the combined count of all other types. This can be useful for a focused component-specific question, but it is not the same as fitting a joint multinomial model. Separate fits do not constrain their predicted probabilities to sum to one, and their implied odds refer to different denominators. They also do not generally reproduce the multinomial model's linear log-ratio structure.
Worked Example: Why Separate One-Versus-Rest Fits Are Different
Consider a hypothetical three-type multinomial model with T as reference, \(\eta_A=x\), and \(\eta_B=0\), where \(x\) is a continuous covariate. The multinomial probabilities are proportional to \((\exp(x),1,1)\). For type B versus the rest, the implied one-versus-rest logit is
At \(x=-1\), this is \(-\log(1+\exp(-1))\approx-0.3133\). At \(x=0\), it is \(-\log(2)\approx-0.6931\). At \(x=1\), it is \(-\log(1+\exp(1))\approx-1.3133\). The successive changes are about \(-0.3799\) and \(-0.6201\), so this implied B-versus-rest logit is not a straight line in \(x\). A separate binary logistic regression that imposes a linear logit for B versus all other types therefore need not agree with the joint multinomial model. The two formulations answer different modeling questions.
Diagnostics, Limitations, and Common Pitfalls
Before interpreting coefficients, check that each donor has a valid count vector, with nonnegative counts and a total equal to the sum across the included cell types. Confirm that the covariates are defined at the donor level and that the condition and covariate design is estimable. Examine category counts across covariate profiles: a type absent from a condition or represented by very few donors can lead to unstable estimates or separation. Very large standard errors, coefficients that grow dramatically under small model changes, or fitted probabilities essentially equal to zero or one are warning signs.
Check whether the chosen linear form is credible for continuous covariates, and whether important interactions are needed. Compare observed donor-level counts with model-implied counts across relevant covariate ranges, rather than relying on one aggregate fit summary. If donors show more variability than the multinomial model allows, standard errors and tests based on that sampling model may be unreliable; the Dirichlet-multinomial and logistic-normal models introduced in earlier material allow additional forms of variation.
- Mistake: interpreting \(\beta_{jC}\) as a change in the proportion of type \(j\). It is a change in the log ratio of type \(j\) to the reference type. Convert predictors to probabilities for a specified covariate profile when proportion-scale summaries are needed.
- Mistake: treating every cell as an independent replicate. The model's independent units are donors, with counts grouped within donors. More cells can make a donor's composition more precisely measured, but do not create more independent donors.
- Mistake: assuming separate one-versus-rest fits are a joint composition model. Their predictions need not sum to one and their odds use distinct denominators. Use the multinomial model when the target is a coherent joint distribution over cell types.
The multinomial model is most useful when the cell categories are defined consistently, donor-level counts are adequate, and the conditional multinomial assumption is a reasonable working model. It does not by itself resolve annotation uncertainty, establish absolute tissue abundance, or remove unmeasured confounding. Its adjusted contrasts describe conditional associations in the sampled donors.
Check Your Understanding
Try each question, then compare your reasoning with the solutions below.
- With T as reference, a one-unit covariate increase has coefficient \(0.4\) for A and \(-0.1\) for B. What is the multiplicative change in \(p_A/p_B\)?
- A donor has three cell types with linear predictors \(\eta_A=0\) and \(\eta_B=\log(2)\), using C as reference. Calculate the three fitted probabilities.
- For five cell types and a binary condition, how many condition coefficients are jointly set to zero in the global condition test?
- Why does an estimated condition coefficient of \(\log(2)\) for A relative to T not mean that the A proportion doubles?
Solutions. 1. The contrast is \(0.4-(-0.1)=0.5\), so the A-to-B probability ratio is multiplied by \(\exp(0.5)\approx1.649\). 2. The weights are \(1,2,1\), with sum 4, so \(p_A=0.25\), \(p_B=0.50\), and \(p_C=0.25\). 3. There are \(K-1=4\) non-reference condition coefficients. 4. The coefficient doubles the A-to-T probability ratio for a one-unit increase; because probabilities are normalized across all cell types, the proportion of A does not generally double.