Default Using R package to implement Bayesian phase I/II dose-finding design for three outcomes

Dear all,

I am trying to implement the work done by Suyu Liu, “A Bayesian Phase I/II Trial Design for Immunotherapy”, using R, since the code attached with that work takes a lot of time (more than 20 hours, and the code not complete). So that I tried to use trialr package since it used rstan, but this package allowed me to use two outcomes ( toxicity, efficacy ) and the work of Liu used three outcomes (immune response, toxicity, and efficacy).

I tried to use the R package trialr for two outcomes using the utility for sensitivity analysis written in R code below (table 1 in the article), I want to see if I used the correct utility and to see how to add a third outcome ( immune response ) to the model

and thanks in advance.

Here is the work of Liu:

https://www.tandfonline.com/doi/supp...260?scroll=top


### My code###
rm(list = ls())
library(trialr)

#Utility
Uti <- array(0,c(2,3,2)) # order: tox, eff, immuno
Uti[,,1] <- matrix(c(0,0,50,10,80,35),nrow=2)
Uti[,,2] <- matrix(c(5,0,70,20,100,45),nrow=2)
N.max= 60 # patients
outcomes <- '1NNN 2NNT 3NNT 4NNN 5NTN'
doses = c(.1,.3,.5,.7,.9)


fit <- stan_efftox(outcomes,
real_doses =doses,
efficacy_hurdle = 0.5, toxicity_hurdle = 0.3,
p_e = 0.1, p_t = 0.1,
eff0 = 0.5, tox1 = 0.65,
eff_star = 0.7, tox_star = 0.25,
alpha_mean = -7.9593, alpha_sd = 3.5487,
beta_mean = 1.5482, beta_sd = 3.5018,
gamma_mean = 0.7367, gamma_sd = 2.5423,
zeta_mean = 3.4181, zeta_sd = 2.4406,
eta_mean = 0, eta_sd = 0.2,
psi_mean = 0, psi_sd = 1,
seed = 123)

ndoses <- length(fit$prob_tox)
plot(1:ndoses, fit$prob_tox, type="b", pch=19, xlab="Dose level", ylab="Probability of toxicity", ylim=c(0,max(fit$prob_tox) + 0.15), col="green")
points(1:ndoses,fit$prob_eff, type="b", pch=18, col="blue")
abline(h=0.3, lwd=2, lty=4, col = "red")
legend(1, 0.4, legend=c("Toxicity", "Effecacy"),
col=c("green", "blue"), lty=1:2, cex=0.8)

Ying has made easy to use software for many of his utility-based phase I-II trial designs freely accessible here. For immunotherapy phase I-II, you could use the more recent U-BOIN approach available here and detailed here.

The correct link to Suyu’s and Ying’s paper in JASA you referred to is here.

1 Like

I know these, I am not looking for software, I am want to implement an R code for further details. Using R code will be flexible for future changes. In his code, he used conjugate beta-binomial prior which takes high cost. But the implementation I did, I used MCMC with trailr and rstan packages. Moreover, his code output a txt file, but I do not know then how he used the simulated data to produce the figures and tables. I ran the code for just 50 iterations it took 15 hours, and it produces a txt file with 50 simulation doses over 60 patients (matrix 50 x 60). If you know how he produced the results, I hope you can feed me back.

here is the simulation data by his code:
https://drive.google.com/drive/folders/13k9_HMWb_GfdaIsOD6nJQQ84_zhy-hRF?usp=sharing

In that case it may be more efficient to contact them directly and discuss these questions. Feel free to message me if you cannot find their contact information and I will put you all in touch.

I am sorry for asking this question if I appear an ignorant. What is the reason for treating immunotherapy phase I-II trials different from utility-base phase ones? Many thanks for a discussion.

1 Like

We know their contact information, Our colleagues contacted them many time, they just gave us the same attached code, they asked them for the part that used to produce the tables and the figures, then they stop replying to us. I do not know why, normally the public research work for public benefit. Thanks for your care, I hope we can find a solution.

I think it help to choose the best dose in comparison with other (toxicity and efficacy)

Blockquote We know their contact information, Our colleagues contacted them many time, they just gave us the same attached code, they asked them for the part that used to produce the tables and the figures, then they stop replying to us

That is unusual as they are quite open and there is nothing really to hide here. Will ask when I get the chance but I know that the pandemic has put quite a strain on statisticians working on multiple COVID-19 trials and protocols so I would not be surprised if your communication got lost in the shuffle. Even statistical methodology journals have been slower to peer review articles than usual due to people being so busy.

Blockquote I am sorry for asking this question if I appear an ignorant. What is the reason for treating immunotherapy phase I-II trials different from utility-base phase ones?

Your question has at least three components:

  1. why use utility-based designs?
    I used to be skeptical of utilities as well but it was Peter Thall and Ying Yuan that changed my mind for good. Dose-finding is a decision and we recently wrote an article describing the value of utilities when making clinical decisions. There are also mathematical advantages (efficiently simplifies modeling) when moving full on into utilities instead of using other “half-way” approaches to incorporate risk-benefit trade-offs.

  2. Why use phase I instead of phase I-II?
    Phase I-II designs perform dose-finding based on both efficacy and toxicity instead of focusing predominantly on toxicity. There are advantages to incorporating the additional information of efficacy when making such decisions. Here is a freely accessible review of the topic.

  3. Is there a difference between immunotherapy dose-finding vs dose-finding for other therapies such as cytotoxic chemotherapy or molecularly targeted agents?
    Tremendous difference. Immunotherapy agents have unique side effect profiles that can appear very remotely to treatment initiation. Their efficacy patterns are also distinct and include phenomena like “pseudoprogression”. Steps have been made in the right direction to address all these, but there is a lot of work to be done.

Hope this addresses your question.

1 Like

many thanks for your rich information,

the author replied to me quickly (Prof. Yuan) when I asked about the full code, but they sent me the code attached with the work (no information there how they produced the results). and when I asked again about how they produced the results, (I mean about the part used to produce the tables and figures); "I sent him two times " after that no response. I am more bioinformatic than a statistician, so I am interested a lot in tools.

My goal is: to use their idea to select the best dose in the first stage and to continue in a second stage with only 2 arms clinical trial and the best dose. (may there is another way to do that?)
That is why I want to understand tool.

Thanks for serving the curiosity of an ignorant :). Sandro