Why a Logistic Basket Model?
In a basket trial, each subgroup may contribute only a small number of binary outcomes. A basket with no observed responses has a maximum-likelihood response estimate of zero, but that estimate alone does not express how uncertain the underlying response probability is. At the other extreme, analyzing every basket independently can leave estimates highly variable. A logistic random-intercept model combines the binomial data with a distribution of basket effects: baskets with limited data are informed by the overall pattern, while baskets with more evidence can depart further from it.
The model is useful when the outcome is binary and the target is a response probability in each basket. Its borrowing depends on the assumed distribution of basket effects. It does not establish that the baskets have identical effects, nor does it guarantee that borrowing is appropriate in every application.
Model and Assumptions
The binomial likelihood assumes that, within basket \(j\), participants have a common response probability and their binary outcomes are conditionally independent given that probability. The normal hierarchy assumes that the basket log-odds are exchangeable draws from one distribution, conditional on \(\mu\) and \(\tau\). Exchangeability means that the model does not assign a different prior status to a basket solely because of its label. It does not mean that the true basket response probabilities are equal.
A full Bayesian fit also assigns priors to the hyperparameters. For illustration, one possible specification is \(\mu\sim N(0,2.5^2)\) and \(\tau\sim\operatorname{HalfNormal}(0,1)\), where the half-normal prior has the distribution of the absolute value of a \(N(0,1)\) variable. These are example choices, not universal defaults: prior predictive implications should be checked against plausible response rates and heterogeneity. In the numerical calculations below, \(\mu=0\) and \(\tau=0.8\) are held fixed to make the basket-level calculation transparent. In a real analysis, uncertainty in these hyperparameters should generally be propagated into subgroup estimates.
What the Posterior Calculation Does
Conditional on \(\mu,\tau\), the posterior density for a basket’s log-odds is proportional to its binomial likelihood times its normal prior density. Ignoring constants that do not depend on \(\theta_j\), its log density is
The posterior mode is the value of \(\theta_j\) that maximizes this expression. Differentiating gives the score equation; differentiating again gives the curvature. The inverse curvature at the mode provides a local variance approximation, known as the Laplace approximation.
The second derivative is negative for every finite \(\theta_j\), since \(n_jp_j(1-p_j)\geq 0\) and \(1/\tau^2>0\). Thus the conditional log posterior is strictly concave and has at most one mode. The Laplace approximation represents the posterior near that mode by a normal distribution with variance equal to the reciprocal curvature.
Record \(y_j\) and \(n_j\) for every basket, and state the likelihood, link, hierarchy, and prior assumptions.
In a full analysis, estimate or sample the hyperparameters and basket effects jointly, using a suitable computation method.
Transform posterior draws of \(\theta_j\) to \(p_j\), then report a probability-scale summary and a credible interval for each basket.
Assess fit to the observed response patterns, sensitivity to heterogeneity assumptions, and whether the posterior computations have converged.
Worked Basket Calculations
With \(\mu=0\) and \(\tau=0.8\), the prior standard deviation is \(0.8\) log-odds units and \(\tau^2=0.64\). The prior median probability is \(\operatorname{logit}^{-1}(0)=0.5\). These values are chosen only for the hypothetical illustrations below.
Worked Example: Four Responses Among Eight Participants
Suppose a hypothetical basket has \(y_j=4\) responses among \(n_j=8\) participants. The score equation is \(4-8p_j-\theta_j/0.64=0\). At \(\theta_j=0\), \(p_j=0.5\), so the score is \(4-8(0.5)-0=0\). The conditional posterior mode is therefore \(\hat{\theta}_j=0\), corresponding to a mode-based probability of \(0.5\).
The curvature at the mode is \(1/0.64+8(0.5)(0.5)=1.5625+2=3.5625\). The Laplace standard deviation is \(1/\sqrt{3.5625}=0.530\) log-odds units. A normal approximation gives a 95% interval for \(\theta_j\) of \(0\pm1.96(0.530)=[-1.039,1.039]\). Transforming the endpoints gives an approximate probability interval of \([0.261,0.739]\).
This interval is an approximate conditional posterior credible interval under the stated fixed hyperparameters. It is not a frequentist confidence interval, and it does not include uncertainty in \(\mu\) or \(\tau\). The probability \(0.5\) is the inverse-logit of the posterior mode, not necessarily the posterior mean of \(p_j\).
Worked Example: No Responses in a Sparse Basket
Now suppose a hypothetical basket has \(y_j=0\) responses among \(n_j=8\). The score equation becomes \( -8p_j-\theta_j/0.64=0\). A numerical solution is \(\hat{\theta}_j\approx-1.192\), for which \(p_j\approx0.233\). Substitution gives a score close to zero: \( -8(0.2329)-(-1.192)/0.64\approx-1.863+1.863\approx0\). The corresponding mode-based response probability is about \(0.233\), rather than the independent maximum-likelihood estimate of zero.
At this mode the curvature is \(1/0.64+8(0.2329)(0.7671)\approx1.5625+1.429\approx2.992\). Thus the Laplace standard deviation is \(1/\sqrt{2.992}\approx0.578\). The approximate 95% interval on the log-odds scale is \(-1.192\pm1.96(0.578)=[-2.325,-0.059]\). Transforming these limits gives an approximate probability interval of \([0.089,0.485]\).
The finite estimate arises because the normal prior gives positive density to finite log-odds, including values above the likelihood’s boundary maximum. The result is pulled toward the prior center, but the data still move the mode below zero. This calculation illustrates moderation by the specified hierarchy; it does not show that a zero-response basket truly has a response probability near the prior median.
Worked Example: One Response and Probability-Scale Interpretation
For another hypothetical basket, let \(y_j=1\) and \(n_j=8\), with the same fixed hyperparameters. Its score equation is \(1-8p_j-\theta_j/0.64=0\). At \(\theta_j\approx-0.871\), \(p_j\approx0.295\), and the score is approximately \(1-8(0.295)-(-0.871)/0.64=1-2.360+1.361\approx0.001\). The mode is therefore about \(-0.871\), corresponding to probability \(0.295\).
The curvature is \(1/0.64+8(0.295)(0.705)\approx1.5625+1.664\approx3.227\), giving a Laplace standard deviation of about \(1/\sqrt{3.227}=0.557\). The approximate 95% log-odds interval is \(-0.871\pm1.96(0.557)=[-1.962,0.220]\), or approximately \([0.123,0.555]\) after inverse-logit transformation.
The mode-based estimate lies between the observed proportion \(1/8=0.125\) and the prior median probability \(0.5\). That is consistent with partial pooling, but the posterior interval remains wide. In a full fit, posterior draws of \(\mu\) and \(\tau\) would also contribute to uncertainty; the conditional calculation understates total uncertainty when those hyperparameters are not known.
Derivation and Interpretation of Partial Pooling
The score equation shows how the observed count and the hierarchy jointly determine the mode:
The left side of the first expression is the likelihood score in log-odds units; the right side is the prior penalty for moving away from \(\mu\). If the data provide little information, the likelihood curvature \(n_jp_j(1-p_j)\) is small relative to \(1/\tau^2\), and the posterior is more strongly influenced by the hierarchy. As information grows, the likelihood can support greater separation from \(\mu\). This is the mechanism behind partial pooling, not a rule that each estimate must move by the same amount.
The scale matters: \(\mu\) is the mean of basket log-odds in the hierarchy, not the logit of the arithmetic mean of the basket probabilities. Because the inverse-logit is nonlinear, \(\operatorname{logit}^{-1}(\mu)\) is the probability at the center of the log-odds distribution, not generally the average basket response probability. If an overall response rate is needed, define the target clearly and calculate it from posterior draws using the intended basket weights.
Diagnostics, Alternatives, and Limitations
Sparse outcomes make careful checking especially important. Examine whether the observed basket counts and response proportions are compatible with posterior predictive data generated from the fitted model. Look for systematic discrepancies across baskets, extreme patterns the model rarely reproduces, and evidence that one common normal distribution of log-odds is implausible. Also check computational diagnostics for posterior sampling, including convergence and adequate effective sample sizes. Compare conclusions under plausible hyperprior scales; when there are few baskets, the data may provide limited information about \(\tau\).
A strong pull toward the center can be consequential when a basket’s response pattern differs from the rest. That is a reason to examine fit and sensitivity, not a reason to discard the hierarchy automatically. Conversely, weakly identified heterogeneity or an overly permissive distribution can reduce borrowing and leave estimates close to separate-basket analyses. These patterns are reasons for scrutiny; they do not by themselves identify a single correct model.
| Approach | What it assumes or provides | Important trade-off |
|---|---|---|
| Independent binomial analyses | Each basket has its own probability without cross-basket borrowing. | Simple and transparent, but sparse baskets can have unstable estimates or boundary estimates. |
| Shared-effect model | Baskets share one response probability. | Uses all observations together, but cannot represent genuine between-basket differences. |
| Logistic random-intercept model | Basket log-odds vary around a common mean with standard deviation \(\tau\). | Allows heterogeneity and partial pooling, but depends on the hierarchy and its priors. |
| Beta-binomial model | Basket probabilities follow a distribution directly on the probability scale. | Also allows heterogeneity; its probability-scale distribution is not interchangeable with a normal distribution on log-odds. |
The logistic hierarchy has limitations. A single normal distribution may not describe distinct clusters of baskets, and one random intercept cannot represent covariates or within-basket dependence not captured by the binomial likelihood. With few baskets, heterogeneity can be difficult to estimate, so subgroup estimates may depend meaningfully on prior assumptions. Finally, a posterior probability or interval describes uncertainty conditional on the model; it does not correct bias from outcome misclassification, selective enrollment, or an inappropriate response definition.
Common Mistakes
- Reporting zero as certainty. Zero observed responses means the sample proportion is zero; it does not establish that the basket response probability is zero.
- Calling a mode a posterior mean. The inverse-logit of the log-odds mode is a mode-based probability summary, not automatically the posterior mean of \(p_j\).
- Ignoring the hyperparameters. Conditional intervals with fixed \(\mu,\tau\) omit uncertainty in those quantities. Use joint posterior draws when reporting full Bayesian uncertainty.
- Assuming partial pooling means equal effects. The hierarchy permits different basket effects. Its degree of pooling depends on the data and the estimated or specified heterogeneity.
- Reading an interval as a data-generating guarantee. A credible interval is a posterior probability statement conditional on the model and priors; it does not guarantee that the model is well specified.
Check Your Understanding
Answer each question, then compare your reasoning with the solutions.
- In the model, what does \(\tau\) measure, and on what scale?
- Why can a basket with zero observed responses have a positive posterior mode for its response probability?
- For the zero-response example, why is the interval \([0.089,0.485]\) approximate rather than an exact full-posterior interval?
- Does a shared-effect model allow basket-specific response probabilities to differ? How does that compare with the random-intercept model?
- Name one assumption that should be checked and one diagnostic that can help assess it.
Solutions. (1) \(\tau\) is the between-basket standard deviation of the log-odds \(\theta_j\). (2) The normal prior assigns density to finite log-odds; combining it with the likelihood produces a finite posterior mode even though the separate-binomial likelihood is maximized at probability zero. (3) It uses a local normal approximation around the conditional mode, transforms its endpoints, and holds \(\mu,\tau\) fixed; it is not the exact posterior interval with hyperparameter uncertainty. (4) A shared-effect model imposes one common probability, whereas the random-intercept model allows basket-specific probabilities centered hierarchically around a common log-odds mean. (5) For example, conditional independence and a common binomial probability within each basket can be assessed in part using posterior predictive checks of basket response counts.