Description Usage Arguments References Examples

This function simulates the phase 3 potion of the phase 123 trial, given phase 12 outcomes.

1 2 3 | ```
SimPhase3(Dose, Phase12, PE, PT, Hypermeans, Hypervars, betaA, ProbC,
betaC, Family, alpha, Nmax, Opt, Accrue, Time12, Twait, NLookSwitch,
NLook, Sup, Fut)
``` |

`Dose` |
Vector of standardized doses considered in the trial. |

`Phase12` |
Matrix Consisting of patient data from a phase 12 trial. The columns are in order: Doses given, YE, YT, Accrual Times |

`PE` |
True efficacy dose-toxicity vector. |

`PT` |
True toxicity dose-toxicity vector. |

`Hypermeans` |
Prior Means for the Eff-Tox design of length 6. |

`Hypervars` |
Prior Variances for the Eff-Tox design of length 6. |

`betaA` |
True linear term for the rate or mean parameter (beta_1,exp(beta_E),-exp(beta_T),beta_2,beta_0) for agent A. |

`ProbC` |
Probability of efficacy and toxicity for the control therapy. |

`betaC` |
Linear term for efficacy, toxicity and beta_0 for the control group. |

`Family` |
Time to event distribution. Options include: Exponential, Gamma, Weibull, Lognormal. |

`alpha` |
Shape parameter or standard deviation of a lognormal distribution. |

`Nmax` |
Maximum number of patients to enroll in phase 3. |

`Opt` |
Dose used for A to begin randomization in phase 3. |

`Accrue` |
Accrual rate for patients in phase 3. |

`Time12` |
Time window for phase 12. |

`Twait` |
Waiting time in between phase 12 and phase 3. |

`NLookSwitch` |
Number of patient events to determine if we re-optimize doses for A. |

`NLook` |
Vector of information criteria for making interim looks. |

`Sup` |
Vector of superiority boundaries. |

`Fut` |
Vector of futility boundaries. |

[1] Chapple and Thall (2018).A Hybrid Phase I-II/III Clinical Trial Design Allowing Dose Re-Optimization in Phase III. Biometrics. In Press,

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 | ```
library(survival)
##True Efficacy and Toxicity Probabilities
PT = c(.1,.15,.25,.35,.5)
PE=c(.2,.4,.6,.65,.7)
##Dose Levels considered
Dose = c(1,2,3,3.5,5)
Dose=(Dose-mean(Dose))/sd(Dose)
##Average accrual rate for phase III
Accrue = 10
#'##Hypermeans for Eff-Tox
Hypermeans = c(.022,3.45,0,-4.23,3.1,0)
Hypervars = c(2.6761, 2.6852, .2, 3.1304, 3.1165, 1)
Hypervars=Hypervars^2
Contour = c(.35, .75,.7,.4)
PiLim = c(.3,.4)
ProbLim=c(.1,.1)
###Family of Distributions
Family="Exponential"
###Shape parameter ## Doesn't matter for exponential distribution
alpha=1
###True Beta vector
betaA = c(.75,-.5, .3, -.25,2.143)
##True beta vector for efficacy, toxicity and intercept of the control treatment
betaC=c(.3,-.25,2.389)
##True efficacy and toxicity probability for control group
ProbC = c(.4,.15)
##Waiting time in between
Twait=1
###How long is the time window in phase 12?
Time12=1
##Dose to start phase 3 with
Opt=3
##Make matrix with old phase 12 data
Doses= c(1,1,1,2,2,2,1,1,1,3,3,3,1,1,1,2,2,2)
YE = c(0,0,1,1,1,0,0,0,0,1,1,1,0,0,1,1,1,0)
YT=c(0,0,0,1,1,0,1,0,0,1,1,1,0,0,0,1,0,0)
##Accrual Times for old data
Accrue12=2
##Size of phase 12 cohort
cohort=3
ACC1=cumsum(rexp(length(YT),Accrue12))
##Accrual times are the same for each cohort in phase 12
Grab = rep(NA,length(YT)/cohort)
for(m in 1:length(Grab)){Grab[m]=ACC1[m*3]}
for(m in 1:length(Grab)){ACC1[((m-1)*cohort+1):((m-1)*cohort+cohort)]=rep(Grab[m],cohort)}
Phase12 = cbind(Doses,YE,YT,ACC1)
betaC=c(.3,-.25,2.389)
##True efficacy and toxicity probability for control group
ProbC = c(.4,.15)
##Max Sample Size
Nmax=500
###Number of patient events to Re-optimize doses
NLookSwitch = 50
##Number of patient events for interim looks
NLook = c(200,300,400)
##Superiority Boundaries
Sup = c(2.96, 2.53,1.99)
##Futility Boundaries (0 means no futility decision)
Fut = c(0,1.001,0)
##Starting Dose, hat(x)_ET
Opt=3
##Number of simulations to run
nSims=10
SimPhase3(Dose,Phase12,PE,PT,Hypermeans,Hypervars,betaA,
ProbC,betaC,Family,alpha,Nmax,Opt,Accrue,
Time12,Twait,NLookSwitch,NLook,Sup,Fut)
``` |

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.