Hierarchical Bayesian model for binary responses

Thall et al. (2003) described a method for analysing treatment effects of a common intervention in several sub-types of a single disease. The treatment effects are assumed to be different but exchangeable and correlated. Observing good efficacy in one cohort, for example, increases one’s expectations of efficacy in other cohorts.

They demonstrate the hierarchical model in a trial with binary response outcomes and in another with time-to-event outcomes. This vignette describes the sarcoma example with binary response outcomes. The authors provide WinBUGS code in the appendix of their paper (Thall et al. 2003). We port their model to Stan and illustrate usage with the example given in their paper.

Implementation in trialr

Statistically, the authors assume that in a trial of \(k\) disease subtypes, the treatment effects are drawn from the same common normal distribution

\(\rho_1, ..., \rho_k \sim N(\mu, \sigma^2)\)

As is the convention in BUGS, the authors define normal distributions by a precision parameter \(\tau\) as opposed to the standard deviation parameter \(\sigma\) used here. We have re-specified the model to comply with the Stan convention of using standard deviation. The authors use a normal hyperprior on \(\mu\), and a gamma hyperprior on \(\tau\), equivalent to an inverse gamma hyperprior on \(\sigma^2\).

We observe \(x_i\) responses in \(n_i\) patients in disease sub-type \(i\). The rate of response in subtype \(i\) is modelled as \(p_i = \text{logit}^{-1}(\rho_i)\). Each \(x_i\) is assumed to be binomially distributed with success parameter \(p_i\). In Stan, that relationship is described as x ~ binomial_logit(n, rho);

The treatment is judged to be worthy of further investigation in cohort \(i\) if

\(\text{Pr}\left\{ p_i > \theta | \mathcal{D} \right\} > q\)

where \(\theta\) is the minimum required response rate, and \(q\) is the required certainty to approve. In their provided example, Thall et al. (2003) use \(\theta = 0.3\).

Example

We reproduce Thall etl al.’s example. We have outcomes in 10 disease subgroups. The number of responses is stored in group_responses and the number of patients in group_sizes. There have been 3 / 7 responses in subgroup 4, for example, but 0 / 2 responses in subgroup 2, and zero patients treated at all in subgroups 1, 6 and 10.

## Inference for Stan model: ThallHierarchicalBinary.
## 4 chains, each with iter=2000; warmup=1000; thin=1; 
## post-warmup draws per chain=1000, total post-warmup draws=4000.
## 
##                     mean se_mean    sd   2.5%    25%    50%    75%  97.5%
## mu                 -0.07    0.03  1.38  -2.84  -0.93  -0.06   0.81   2.65
## sigma2             12.31    0.34 10.17   3.39   6.26   9.32  14.68  39.94
## rho[1]             -0.09    0.07  3.94  -8.28  -2.35  -0.06   2.25   7.82
## rho[2]             -3.06    0.06  2.64  -9.31  -4.28  -2.63  -1.34   0.78
## rho[3]              2.26    0.05  2.62  -1.80   0.51   1.87   3.60   8.45
## rho[4]             -0.31    0.01  0.79  -1.95  -0.80  -0.27   0.19   1.17
## rho[5]              3.71    0.05  2.32   0.50   2.09   3.29   4.79   9.47
## rho[6]             -0.07    0.06  3.79  -7.71  -2.40  -0.03   2.16   7.67
## rho[7]             -0.02    0.03  1.59  -3.24  -1.00  -0.02   0.98   3.09
## rho[8]              0.74    0.02  1.30  -1.76  -0.13   0.70   1.55   3.52
## rho[9]             -2.41    0.06  2.71  -8.70  -3.83  -2.09  -0.59   1.87
## rho[10]            -0.03    0.07  3.76  -7.53  -2.30  -0.04   2.20   7.72
## sigma               3.31    0.04  1.16   1.84   2.50   3.05   3.83   6.32
## prob_response[1]    0.49    0.01  0.38   0.00   0.09   0.49   0.90   1.00
## prob_response[2]    0.15    0.00  0.19   0.00   0.01   0.07   0.21   0.69
## prob_response[3]    0.77    0.00  0.26   0.14   0.62   0.87   0.97   1.00
## prob_response[4]    0.43    0.00  0.17   0.12   0.31   0.43   0.55   0.76
## prob_response[5]    0.92    0.00  0.10   0.62   0.89   0.96   0.99   1.00
## prob_response[6]    0.49    0.01  0.38   0.00   0.08   0.49   0.90   1.00
## prob_response[7]    0.50    0.00  0.27   0.04   0.27   0.50   0.73   0.96
## prob_response[8]    0.63    0.00  0.23   0.15   0.47   0.67   0.82   0.97
## prob_response[9]    0.22    0.00  0.26   0.00   0.02   0.11   0.36   0.87
## prob_response[10]   0.50    0.01  0.38   0.00   0.09   0.49   0.90   1.00
## lp__              -34.39    0.14  3.66 -42.74 -36.53 -33.89 -31.73 -28.77
##                   n_eff Rhat
## mu                 2449    1
## sigma2              875    1
## rho[1]             3231    1
## rho[2]             1731    1
## rho[3]             2368    1
## rho[4]             3956    1
## rho[5]             1803    1
## rho[6]             3454    1
## rho[7]             3519    1
## rho[8]             3595    1
## rho[9]             2222    1
## rho[10]            3027    1
## sigma               872    1
## prob_response[1]   3695    1
## prob_response[2]   3892    1
## prob_response[3]   4315    1
## prob_response[4]   4062    1
## prob_response[5]   4369    1
## prob_response[6]   3898    1
## prob_response[7]   3863    1
## prob_response[8]   3966    1
## prob_response[9]   4245    1
## prob_response[10]  3360    1
## lp__                722    1
## 
## Samples were drawn using NUTS(diag_e) at Fri May 24 16:24:57 2019.
## For each parameter, n_eff is a crude measure of effective sample size,
## and Rhat is the potential scale reduction factor on split chains (at 
## convergence, Rhat=1).

The probability of response in each subgroup is calculated under prob_response. We can use the generic summary function from rstan to get a nice summary:

knitr::kable(rstan::summary(fit, par = 'prob_response')$summary, digits = 3)
mean se_mean sd 2.5% 25% 50% 75% 97.5% n_eff Rhat
prob_response[1] 0.495 0.006 0.383 0.000 0.087 0.486 0.905 1.000 3695.345 1.000
prob_response[2] 0.146 0.003 0.185 0.000 0.014 0.067 0.208 0.686 3891.846 1.001
prob_response[3] 0.765 0.004 0.255 0.142 0.624 0.867 0.973 1.000 4314.696 1.001
prob_response[4] 0.433 0.003 0.168 0.125 0.310 0.432 0.548 0.764 4062.484 1.000
prob_response[5] 0.922 0.002 0.105 0.624 0.890 0.964 0.992 1.000 4369.098 1.000
prob_response[6] 0.494 0.006 0.382 0.000 0.083 0.494 0.897 1.000 3898.022 1.001
prob_response[7] 0.497 0.004 0.273 0.038 0.269 0.495 0.726 0.956 3863.455 0.999
prob_response[8] 0.635 0.004 0.228 0.146 0.469 0.668 0.825 0.971 3965.720 1.000
prob_response[9] 0.223 0.004 0.255 0.000 0.021 0.110 0.357 0.867 4244.608 1.000
prob_response[10] 0.497 0.007 0.381 0.001 0.091 0.491 0.900 1.000 3359.594 1.000

Let us say that we are willing to approve the treatment for further study in a subgroup if we have at least \(q = 70\)% certainty that the probability of efficacy exceeds the target response rate of 30%.

##  prob_response[1]  prob_response[2]  prob_response[3]  prob_response[4] 
##           0.59725           0.16850           0.91925           0.77375 
##  prob_response[5]  prob_response[6]  prob_response[7]  prob_response[8] 
##           0.99825           0.59425           0.71150           0.90825 
##  prob_response[9] prob_response[10] 
##           0.29000           0.59900

On that basis, at this interim stage, we would be eager to approve the treatment in subgroups 3, 5 and 8. Subgroups 4 and 7 are close to the boundary.

Some distribution plots of the probabilities of efficacy in some subgroups may be informative.

library(ggplot2)
library(rstan)
library(dplyr)

plot(fit, pars = 'prob_response') + 
  geom_vline(xintercept = 0.3, col = 'orange', linetype = 'dashed') +
  labs(title = 'Partially-pooled analysis of response rate in 10 sarcoma subtypes')
Prob(Response | D) in subgroup 3

Prob(Response | D) in subgroup 3

We see that the inferred efficacy in subgroup 5 is very high. In contrast, efficacy is subject to more uncertainty in subgroup 4, but the majority of the mass clearly lies to the right of 30%.

References

Thall, Peter F., J. Kyle Wathen, B. Nebiyou Bekele, Richard E. Champlin, Laurence H. Baker, and Robert S. Benjamin. 2003. “Hierarchical Bayesian Approaches to Phase II Trials in Diseases with Multiple Subtypes.” Statistics in Medicine 22 (5): 763–80. https://doi.org/10.1002/sim.1399.