HAL Id: hal-01737106
https://hal-univ-rennes1.archives-ouvertes.fr/hal-01737106
Submitted on 18 Jul 2019
HAL is a multi-disciplinary open access archive for the deposit and dissemination of sci- entific research documents, whether they are pub- lished or not. The documents may come from teaching and research institutions in France or abroad, or from public or private research centers.
L’archive ouverte pluridisciplinaire HAL, est destinée au dépôt et à la diffusion de documents scientifiques de niveau recherche, publiés ou non, émanant des établissements d’enseignement et de recherche français ou étrangers, des laboratoires publics ou privés.
dfpk An R-package for Bayesian dose-finding designs using pharmacokinetics (PK) for phase I clinical trials
A. Toumazi, E. Comets, C. Alberti, T. Friede, F. Lentz, N. Stallard, S. Zohar, M. Ursino
To cite this version:
A. Toumazi, E. Comets, C. Alberti, T. Friede, F. Lentz, et al.. dfpk An R-package for Bayesian dose-
finding designs using pharmacokinetics (PK) for phase I clinical trials. Computer Methods and Pro-
grams in Biomedicine, Elsevier, 2018, 157, pp.163-177. �10.1016/j.cmpb.2018.01.023�. �hal-01737106�
ContentslistsavailableatScienceDirect
Computer Methods and Programs in Biomedicine
journalhomepage:www.elsevier.com/locate/cmpb
dfpk: An R-package for Bayesian dose-finding designs using pharmacokinetics (PK) for phase I clinical trials
A. Toumazi
a, E. Comets
b,c, C. Alberti
d, T. Friede
e, F. Lentz
f, N. Stallard
g, S. Zohar
a,1, M. Ursino
a,1,∗aINSERM, UMRS 1138, Team 22, CRC, University Paris 5, University Paris 6, Paris, France
bINSERM, CIC 1414, University Rennes-1, Rennes, France
cINSERM, IAME UMR 1137, University Paris Diderot, Paris, France
dINSERM, UMR 1123, Hôpital Robert-Debré, APHP, University Paris 7, Paris, France
eDepartment of Medical Statistics, University Medical Center Göttingen, Göttingen, Germany
fFederal Institute for Drugs and Medical Devices, Bonn, Germany
gStatistics and Epidemiology, Division of Health Sciences, Warwick Medical School, The University of Warwick, UK
a rt i c l e i n f o
Article history:
Received 30 June 2017 Revised 11 January 2018 Accepted 24 January 2018
Keywords:
Dose-finding
Maximum tolerated dose Pharmacokinetics Phase I clinical trials R package
a b s t r a c t
Backgroundand objective: Dose-finding, aimingatfinding the maximumtolerateddose, and pharma- cokineticsstudiesarethefirstinhumanstudiesinthedevelopmentprocessofanewpharmacological treatment.Intheliterature,todateonlyfewattemptshavebeenmadetocombinepharmacokineticsand dose-findingandtoour knowledgenosoftwareimplementationis generallyavailable. Inpreviouspa- pers,weproposedseveralBayesianadaptivepharmacokinetics-baseddose-findingdesignsinsmallpop- ulations.Theobjectiveofthisworkistoimplementthesedose-findingmethodsinanRpackage,called
dfpk.
Methods: AllmethodsweredevelopedinasequentialBayesiansettingandBayesianparameterestima- tioniscarriedoutusingtherstanpackage.Allavailablepharmacokineticsandtoxicitydataareusedto suggestthedoseofthenextcohortwithaconstraintregardingtheprobabilityoftoxicity.Stoppingrules arealsoconsideredforeachmethod.Theggplot2packageisusedtocreatesummaryplotsoftoxicities orconcentrationcurves.
Results: Forallimplementedmethods,dfpkprovidesafunction(nextDose)toestimatetheprobability ofefficacyandtosuggestthedosetogivetothenextcohort,andafunctiontoruntrialsimulationsto design atrial (nsim). The sim.data functiongeneratesateachdose thetoxicity valuerelatedto a pharmacokineticmeasureofexposure,theAUC,withanunderlyingpharmacokineticonecompartmental modelwithlinearabsorption.It isincludedasanexamplesincesimilar data-framescanbegenerated directlybytheuserandpassedtonsim.
Conclusion: Thedevelopeduser-friendlyRpackagedfpk,availableontheCRANrepository,supportsthe designofinnovativedose-findingstudiesusingPKinformation.
© 2018TheAuthors.PublishedbyElsevierB.V.
ThisisanopenaccessarticleundertheCCBY-NC-NDlicense.
(http://creativecommons.org/licenses/by-nc-nd/4.0/)
1. Introduction
Dose-findingstudiesandpharmacokinetics(PK)arecarriedout atthefirstphasesofclinicalevaluationofanewdruginhumans.
Drug safetyisevaluatedin thedose-findingstudy,whichaims at identifyingthemaximumtolerateddose(MTD)[1].Meanwhile,the
∗ Corresponding author..
E-mail address: moreno.ursino@inserm.fr (M. Ursino).
1The last two authors contributed equally as co-senior authors.
PKdatacollectedduringsuchstudyprovidesthedescriptionofthe dose-concentration relationships[2]. Nevertheless, these two ap- proaches are oftenconductedandreported independently indif- ferentsectionsinpublicationsreportingtrialresults[3].Identifying therightdoseorsetofdosesatanearlystageiscrucial:selecting too toxic doses can result in patient overdosing, while selecting an inefficientdose increasesthe likelihood that the drug willbe found to be ineffectivein subsequentclinical evaluation [4]. Par- ticularlyinthecaseofsmallpopulations,suchasrarediseasesor paediatrics, itshould beusefulto take intoaccount all theinfor- https://doi.org/10.1016/j.cmpb.2018.01.023
0169-2607/© 2018 The Authors. Published by Elsevier B.V. This is an open access article under the CC BY-NC-ND license. ( http://creativecommons.org/licenses/by-nc-nd/4.0/ )
mationcollectedduringthetrial,andtotrytoutilizethePKmea- surementswithinthedose-findingdesign.Onlyfewattemptshave beendescribed inthe literature so far and, usually,the methods were built fora very specific situation [5–8]. Moreover, no soft- wareimplementationsarepubliclyavailable.
In thisarticle wepresent thenewR package
dfpk
(short for dose-findingPharmacokinetics),whichprovidestheBayesianadap- tivePK-baseddose-findingdesigns insmallpopulations proposed byUrsinoetal.[8]throughthefreelyavailableRsoftware[9].The sixmethods detailedin[8]havebeenimplementedindfpk
.Foreachofthem,twofunctionsareprovided: (i) afunctionto deter- mine the next recommended dose (during the trial) or the rec- ommended MTD (at the end of the trial) and (ii) a function to runsimulations of phase Istudies to designa newtrial.Interac- tive graphicalrepresentations ofthe dose-concentration curve, of thedoseallocationprocessinthetrialandofthedose-toxicityre- sponsearealsoprovidedbythepackage.
Thepaperisorganisedasfollows.Section2introducesthesta- tisticalmethodsproposed byUrsinoetal.[8],alongwiththede- scriptionofthesuggestedscenariostobesimulated.Section3out- linesthe structure ofthe package andthe main functionsof the paper(
sim.data
,nextDose
andnsim
)withpracticalexamples.Section4&5includeconclusion,discussionandrecommendations.
2. Computationalmethods
The presentsection briefly reviews the methods proposed by Ursino et al. [8]to perform dose-finding takinginto account PK measurements.Wethendescribethescenariossimulatedin[8]in orderto evaluatetherobustnessofthemethod,whichhavebeen addedasexamplesinthedfpkpackage.
2.1.Dose-findingmethods
Let D=
{
d1,...,dk}
be the set of K possible doses withd1<<dkandd[i]∈Dbethedoseadministeredtotheithsubject (i=1,...,n,wherendenotesthesamplesize)andyibeabinary variablewhichtakesvalue 1iftheithsubjectshowsaDLT(dose- limitingtoxicity)and0otherwise.Moreover,letzibethelogarithm oftheareaunderthecurve(AUC)oftheconcentrationsofdrugin bloodplasmaagainsttime,fortheithpatient.
All methods share the same fundamental idea for the dose- escalation rule: the dose chosen for the next cohort enrolled is the one with probability of toxicity nearest to the target
θ
se-lected by the trial investigators. A no-skipping rule is given: if some doses have not yet been tested, the dose is chosen from D∗⊂D,a subset ofD whichcontainsall the dosesalreadyevalu- atedandthe firstdoselevelimmediatelyabove.Thefinal recom- mendedMTD isgiven bythe dosethat wouldhavebeenadmin- isteredfor the (n+1)st subject enrolledin the trial.Finally, we addedinallmethodsthesamestoppingrule:iftheposteriorprob- abilityoftoxicityofthefirstdoseisgreaterofaspecifiedthresh- old,thennodoseissuggestedandthetrialisstopped.
Eachmethodisseparatedfromtheothers.Weadoptedthecon- ventionofstartingthesubscriptionof
β
parameterfrom0foreachmethod.Therefore,evenifthe parametersshare thesamenames acrossmodels,theyhavedifferentinterpretations.Inthefollowing, webrieflydescribehowtheprobabilityoftoxicityisestimatedand computedineachmethod.
2.1.1. PKCOV
PKCOVisamodificationofthemethodproposedbyPiantadosi andLiu[5]whosuggestedtousetheAUCasacovariateforpT,the probabilityoftoxicity, throughthelogit link.Therefore,thedose-
toxicitymodelis
logit
(
pT(
dk,zdk,β
) )
=−β
0+β
1log(
dk)
+β
2zdk
∀
dk∈D, (1) whereβ
=(β
1,β
2),β
0 isaconstantselectedthroughasensitivity analysisorwithpriorinformation,zdkisthedifferencebetween thelogarithmofpopulationAUCatdosedkandz,thelogarithmof AUCofthesubjectatthesamedose.Independentuniformdistri- butionsareselectedaspriordistributionsforβ
1andβ
2.Indetail,β
1∼U(max(0,m1−5),m1+5),wherem1reflectsthepriorinfor- mationontheparameterandthelengthofthedomainofthedis- tributioncangoupto10,andβ
2∼U(0,5).Bothβ
0andm1should beselectedusingprior information,such asfrompreclinicaldata, and sensitivity analysisshould be done. The estimated probabil- ityof toxicity versus doseis obtained by invertingEq. (1),usingβ
1=β
ˆ1,theestimatedparameter,andzdk=0. 2.1.2. PKLIMandPKCRMPKLIM isa modification ofthe methodproposed by Patterson etal.[6]andWhiteheadetal.[10].AnormalPK-toxicitymodelis used:
zi
| β
,ν
∼Nβ
0+β
1logdi,ν
2, (2)
where
β
=(β
0,β
1) are the regression parameters, andν
is thestandard deviation. A bivariate normal distribution and a beta distribution are chosen for
β
andν
, respectively, that is,β
∼ N(m,ν
2(g))andν
∼Beta(1,1).Therefore,ahierarchicalpriordis- tributionisgiventoβ
,wherem=(−logClpop,1)andgshouldbe chosenusingpriorinformation.Forinstance,Clpopdenotestheat- tendedvalueoftheclearanceatpopulationlevel,andgreflectsthe precision. Theprobability oftoxicity ofeachdoseiscomputedas P(
z>L|
dk,β
=β
ˆ,ν
=ν
ˆ) ∀
dk∈D, (3) whereLisathresholdsetbeforestartingthetrialandthehatde- notestheposteriormeansoftheparameters.Sinceanassumption underlyingthemodelisthatDLTsarebasedontheAUCexceeding some threshold,the methodcould be applicable only when such a thresholdisknown.In ordertoavoidthisproblem, thePKCRM methodwasproposed,whichisthecombinationofPKLIMandthe CRM[11] usingapower workingmodelandnormalprior onthe parameter.InPKCRMthedoserecommendedforthenextsubject isthelowestofthedosesrecommendedbythetwomethods.Notethat although the samenotationhas beenused forcon- venience,theparameters
β
0 andβ
1 are differentinthedifferent models.2.1.3. PKLOGIT,PKPOP,PKTOX
PKLOGIT,inspiredbyWhiteheadetal.[7],combinestworegres- sions to compute the probability oftoxicity versus the dose. The firstoneisthesameasEq.(2),thatiszversusdose.Inthesecond, z isusedasacovariateina logisticregressionmodelforpT.This meansthatnowtheprobabilityoftoxicityisdescribedintermof AUCandnotanymoreintermofdose.Therefore,wehavethat logit
(
pT(
z,β ))
=−β
2+β
3z, (4)where
β
2 andβ
3 have independent uniform prior distributions, thatis,β
2∼U(0,m2) andβ
3∼U(0,m3),withm2≥m3,andvalues can bechosen usingprior information.Ifnoinformationis avail- able,m2=20andm3=10aregoodstartingvaluesforasensitiv- ityanalysis.The probability oftoxicity associatedwith eachdose isobtainedby usingthe estimatedparametersofeach regression modelinthefollowingexpectedvalueformula:P
(
y=1|
dk,β
=β
ˆ,ν
=ν
ˆ)
=E 1 1+eβˆ2−βˆ3z=
1
1+eβˆ2−βˆ3z
g
(
z)
dz, (5)where g(z) represents the distribution of the logarithm of AUC giventhedosedkobtainedfromEq.(2).
PKPOP,avariationofPKLOGIT,arisesbyreplacingzwithzk,pop inEq.(4),wherezk,popisthemeanvalueofthelogarithmofAUC atdosedkpredictedbyEq.(2).Inotherwords,wereplacetheob- servedAUCvalue forthepatientwiththepopulationmeanvalue.
Then, theprobability oftoxicityateach doseiscomputedinvert- ing Eq.(4),usingtheestimatedparameters
β
ˆ2 andβ
ˆ3 along with zk,poppredictedbyEq.(2).PKTOXisessentiallythePKLOGITmethodwithaprobitregres- sionmodelreplacingthelogisticregressioninEq.(4),thatis pT
(
z,β )
=(
−β
2+β
3z)
, (6) with represents the standard cumulative normal distribution.As intheprevious models,independentuniformdistributions are chosen as prior distributions for the parameters. The probabil- ity oftoxicity versus doseis then computedin the sameway of Eq.(5)usingtheprobitregressioninsidetheintegral.
2.1.4. DTOX
DTOX follows the usual wayof estimating pT versus dose di- rectlywithoutthePK measurementsandisincludedtocheckthe behaviourofthisstandardmethod.Thedose-toxicitymodelis:
pT
(
dk,β )
=(
−β
0+β
1log(
dk)) ∀
dk∈D. (7) Independentuniformbivariatepriordistributionischosenforβ
inthesamewayofEq.(4).
2.2. Simulatingdatafortrialdesign
Thepackageimplementsseveralexamplesreproducingthesce- nariosproposedinUrsinoetal.[8]toevaluatethemethodperfor- manceusingsimulateddata.Inthesesettings,toxicityislinkedto a PK measure ofexposure,namely toAUC, andwe useda simu- lation settingsimilar to the one in[12].A first orderabsorption, linear,one compartmentPK modelwasusedtosimulatePKdata.
Inthismodel,theconcentrationattimetafteradministrationofa dosedkofthedrugattime0,canbe writtenasa functionofka, theabsorptionrateconstantfororaladministration,CL,theclear- ance ofelimination, andV,thevolumeofdistribution,asfollows:
c
(
t)
=dkV ka
ka−CL/V
e−(CL/V)t−e−kat
, (8)
IndividualCLandVare sampledfromlog-normaldistributions withmeanCLpop(Lh−1)andVpop(L),respectively,andstandardde- viation
ω
CL=ω
V,while ka isfixed inthis studyaslimitedinfor- mationconcerningtheabsorptionphasewasavailableintheorig- inaldataset toestimate its inter-individualvariability.In orderto link PK to the toxicity profile of patients, a sensitivity parame- terα
,comingfromalog-normaldistributionwithmeanequalto 1 andstandard deviationω
α, anda thresholdτ
T are introduced.Weassumedthatapatient incursadoselimitingtoxicity(DLT)if
α
AUC≥τ
T.Choosingthedifferentparameters leadstoseveralsce- narios.Theprobabilityoftoxicityiscomputedas:pT
(
dk)
=logdk−log
τ
T−logCLω
CL2 +ω
2α. (9)
3. R-functions
Package
dfpk
implements all the dose-finding methods de- scribed inSection 2. InFig.1,an overallexplanation ofthemain functions inthedfpk
package is given. The aim of the package is to assist the design ofphase I clinical trials. During the trial, the patient data already accrued (“Trial data” in Fig. 1A) can be used in thenextDose
function in order to determine the nextFig. 1. Overall presentation of the main R functions nextDose (Fig. 1A) and nsim (Fig. 1B) available in the package dfpk, indicating the corresponding inputs and out- puts.
recommended dose, or the MTD at the end of trial. Plots are alsoavailable aftertheestimationprocess. Whenplanninga new trial, datasets containing PK and toxicity measurements can be simulateddirectly by the user (“Simulated data”) or through the
sim.data
function,andused inthensim
function (inFig. 1B.),which will perform n simulated clinical trials. Also in this case, plotswithgraphicalrepresentationssupportthenumericresults.
Bayesianparameterestimationiscarried outusingthe
rstan
packagewhilethe
ggplot2
packageisusedtocreateplots.ThreeS4 classesare implemented in thepackage, “dose” ,“dosefinding”
and“scen”,inorderto store theoutputs ofthe mainR functions
nextDose
,nsim
andsim.data
,respectively.Theclassesarede- taileddescribedintheAppendixB.Thepackage
dfpk
isavailableontheCRANarchiveandcanbe easily installed on the fly through the URL https://cran.r-project.org/web/packages/dfpk. Once the package is installed, it can be loadedwiththecommand:
In the remainder of this section, we present the R functions availableinthepackagealongwiththerequiredinputparameters andexamples.Amoreextensivedemonstrationanddocumentation canbeaccessedfromtheon-lineusermanualontheCRANserver byinstallingthepackageordirectlywithintheRconsole.
Table 1
Arguments for the functions nextDoseand the dose-finding models.
model The dose-finding model chosen between “pktox”, “pkcov”, “pkcrm”, “pklogit”,
“pkpop” and “dtox”.
y A binary vector of toxicity outcomes from previous patients.
AUCs A vector with the computed AUC values of each previous patient for PKTOX, PKCRM, PKLOGIT and PKPOP.
doses A vector with the doses panel.
x A vector with the dose level assigned to previous patients.
theta The toxicity target.
options List with the Stan model’s options.
prob The threshold of the posterior probability of toxicity for the stopping rule in the selected model; defaults to 0.9.
betapriors A vector with the value for the prior distribution of the regression parameters in the selected model.
thetaL A second threshold of AUC in the PKCRM model only; defaults to theta for PKCRM and NULL for the models PKTOX, PKCOV, PKLOGIT, PKPOP & DTOX.
p 0 The skeleton of CRM for PKCRM; defaults to NULL.
L The AUC threshold to be set before starting the trial for PKCRM; defaults to NULL.
deltaAUC A vector of the difference between computed individual previous patients’ AUC and the AUC of population at the same dose level (defined as an average);
argument for PKCOV; defaults to NULL.
CI A logical constant indicating the estimation of the 95% credible intervals (CI) of the probability of toxicity at each dose level for the selected model; defaults to TRUE.
Table 2
Input arguments required by each dose-finding method in the nextDose function.
Method Required arguments Optional arguments
pktox y, AUCs, doses, x, theta, prob, options, CI betapriors pkcov y, AUCs, doses, x, theta, deltaAUC, prob, options, CI betapriors pkcrm y, AUCs, doses, x, theta, p0, L, prob, thetaL, options, CI betapriors pklogit y, AUCs, doses, x, theta, prob, options, CI betapriors pkpop y, AUCs, doses, x, theta, prob, options, CI betapriors dtox y, doses, x, theta, prob, options, CI betapriors
3.1.Dose-findingmethods(
nextDose
)The
nextDose
functionisusedtoperformparameterestimationateachstepduringadose-findingtrial.It givestherecommended dosetoadministertothenext cohortofpatients, orthefinal estimatedMTD ifappliedattheendofthetrial.Itcan beusedduringan ongoingclinicaltrialorwithasimulateddataset,asdescribedlaterintheSection3.2.The description ofthe input argumentsused in the
nextDose
functionare provided in Table1. Theuser hasto choosethe dose- finding methodfrom the available set in themodel
parameter. Then, he/she should provide the parameters required by the selectedmethod,asspecifiedinTable2,whiletheothersaresetautomaticallytoNULL.Anyargumentnotspecifiedbytheuserwillbesettothe correspondingdefaultchoice[8].The numberofchainsanditerationsforthe Bayesianalgorithmcan bechanged usingtheappropriate
rstan
options.3.1.1. Demonstration
(A)PKTOXmodelInthefollowingexample,wesupposed thataclinicaltrialisstill ongoingand15patientshavebeenenrolledsofar.
Forthiscase,PKTOXwasselectedasthedose-findingmodel.The
nextDose
functionrequiresthefollowinginputarguments:the panel ofdosesofthedrug,thetargettoxicityprobability,θ
andtheoptionsfortheStanmodelasalist,containingthenumberofchains,thenumberofiterationsandthewarm-upiterations.
Othernecessaryinputargumentsarethevectorofdoselevelsassignedtothepatients(asintegervector),thatisdenotedby
x
,theAUCsvaluesandthevectoroftoxicityoutcomes(0/1areaccepted),denotedas
y
,foreachenrolledpatient.Theusercanchangethepriordistributionparameterofthetoxicity-AUCregressionbyaddingtheparameter
betapriors
.Ifitis notspecified,thevaluesuggestedbyUrsinoetal.[8]areusedbydefault.ThedefaultchoicesofbetapriorsforPKTOXmodelarethefollowing:
β
| ν
∼N(
m,ν
×g×diag(
1,1) )
,ν
∼Beta(
1,1)
, m=−log
CLpop
,1,
β
2 ∼U(
0,beta2mean)
,β
3 ∼U(
0,beta3mean)
, (10)whereClpop isthepopulation clearanceandthedefaultchoicesareClpop=10,g=10000,beta2mean= 20andbeta3mean= 10.
Detailsaboutthedefaultchoicesofallthedose-findingmodelsareavailableintheuser-manualontheCRAN.
Theseargumentsareusedinthe
nextDose
functiondependingonthechosenmodel,PKTOX,usingthefollowingsyntax:omittingalldefaultparameters.
Theresultsarestoredina“dose”object.Theoutputbelowreportspartoftheresultsdisplayed,thatisthenumberofpatientswho arecurrentlyenrolled,theselecteddose-findingmodel,andtheobserveddoselevelsofthedrug:
Accordingto theseresults,thenext recommendeddoselevelis5,whichwouldbe thedoseforthenext cohortofpatientsgiven thedata.Theestimatedtoxicityprobabilitiesandmodelparametersarealsoshown:
The packagealso providesa graphicalrepresentationof theresults.Forexample,usingthe genericfunction
plot()
on a “dose”object,wecanselectifwewanttopresentgraphically:(1)thedoseallocationofthecurrentlyenrolledpatientsduringthetrialor (2)theposteriordistributions oftheprobability oftoxicityateachdosepresentingtheestimationalongwiththelinesofthe95%
credibleintervals(CI),asbelow:
Fig.2presents(A)thedataforthefirst15patientsinthestudy,and(B)theplotoftheposteriordistributions giventhisdata of theprobabilityoftoxicityateachdoseaccordingtothePKTOXmethod(includingthemeanestimationalongwiththe95%CI).
(B) PKCRMmodel
InthissectionasecondillustrationisshownusingthePKCRMdose-findingmethodinthefunction
nextDose
.Inthisway,wecanhighlightthedifferencesintherequiredinputs/outputs.Inthiscase,inadditiontotheinputargumentsthatareusedinthePKTOX
Fig. 2. (A) Plot of the data for the first 15 patients in the study and, (B) the plot of the posterior distributions given this data of the probability of toxicity at each dose according to the PKTOX method (including the mean estimation along with the 95% CI).
method (i.e.y,AUCs, doses,x, theta, options), thePKCRMmethod requirestheskeleton ofCRM (
p0
) andtheAUC threshold(L
), whichmustbesetbeforestartingthetrial.Inthisexampleweuse:AftersettingalltherequiredargumentsforthechosenPKCRMmodel,wecallthenextDosefunctionasfollowing:
Theresultingobjectdisplaysasfollows:
3.2.
Generate data (sim.data)
The
sim.data
functiongeneratesandstoresPKandtoxicitydatainordertobeusedforsimulationaccordingtothemodeldescribedinSection2.2.Theinitialstepconsistsingeneratingthepatients’ responsesatalldosesforeachtrial.Thefunction
sim.data
takesthe trial’ssettingsandreturnsalistofdataincludingthesubject’sPKparametersalongwiththesimulatedtoxicityobservations.Inparticular,itstartsbydrawingsubject’sPK parameters(kα,CLandV) fromthe populationdistributionsdefinedbythepopulation mean(
PKparameters
) andtheinter-individualvariability(IIV)fortheclearanceandthevolumeofdistribution(omegaIIV
). Then,for each doselevel(doses
), wecomputed thedesiredprobability oftoxicity (preal
), andforall patients(N
) andsimulateddata (TR
),itcomputestheconcentrationmeasurementsatthespecifiedtimepoints(
timeSampling
).Inaddition,weaddaproportionalerrordrawn from a normaldistribution withzero mean anda standard deviationsigma
. Accordingto eq. (9), the function computesthe toxicity valuesforeachdoselevelusingthethresholdlimitTox
andthepatient’ssensitivityparameteromegaAlpha
.Finally,adefaultvalueoftherandomnumbergenerator(
seed
)issetat190591.Theresultsarestoredinalistof“scen”objects,whichconsistsof
PKparameters
,nPK
,thelengthofthetimepoints,timeSampling
,idtr
,N
,doses
,preal
,limitTox
,omegaIIV
,omegaAlpha
,concentration
, the concentration computed at the PK population values,concPred
,theconcentration valueswithproportional errorsforeach patientateach dose,tox
,tab
,a summarymatrix,used inthesimulationfunction,containingthesamplingtimepointsatthefirstrowfollowedbyconcPred
,parameters
,thesimulatedPK parameters ofeach patient,alphaAUC
,theα
AUCs. Since we are usingS4 classes,theusercan easily createhis/herown datasets. Forexample,he/shecancreateanewobjectforeachsimulatedtrial,named
UserData
,usingthecommandnew
inthefollowingwayandthen add itin alist, alongwiththe other simulateddatasets.A moreexpanded descriptionofthe “scen”class andobjectscan be accessedfromAppendixB2.
3.2.1. Demonstration
Thefollowingillustrationshowshowtogeneratethedatasetsofthefirstscenariodescribedby Ursinoetal.[8].Inthisexample,we setthenumberoftrialsto10(i.e.
TR
=10),thethresholdoftoxicityvalueto10.96,thedoselevelsto(12.6,34.655,44.69,60.807,83.689 and100.371mg)whichareusedtoobtainthetrueprobabilitiesoftoxicity,48evenlyspacedsamplingtimepointsbetween0and48h,a samplesizeof30andka=2,CL=10andV =100asillustratedbelow:Eachtrial’sresultisstoredinalistoftheR“scen”object,
gen.scen
,whichregroupsthesubject’sPK parameters,theconcentration measurements forall patientsandthesimulatedtoxicities valuesateachdoselevel.Here, we providesomesim.data
resultsforthefirsttrial:
BasedontheaboveAUCwiththesensitivityparametervaluesandthechosentoxicitythreshold
τ
T=10.96,weobserveforallpatients (onerow=onepatient)inthesecondtrial,thetoxicityoutcomesateachdoselevel(onedose=onecolumn)asfollows:Fig. 3. Plot of the concentration of the drug vs time for 12.6, 34.65, 44.69, 60.8, 83.69 and 100.37 mg with k a= 2 h 1, CL = 10 Lh 1and V = 100 L .
Inthisexample,weused
α
=1forallpatients,buttheusercansimulateα
fromalog-normaldistributionwithmean=1andstandard deviationω
α.Selectingω
α=0impliesα
=1asinthisexample.Onceagain,providingtheselectedlistofthegenerated“scen”objecttothegenericplotfunction
plot
,theuserobtainsaplotofthe drug’sconcentrationintheplasmaagainstthetimet.Underthesamesettingsandoutputsasabove,theplotisimplementedasfollows:Fig.3presentsthePKconcentration curves,describedinSection 2,withthePK parameterskα=2h−1,CL=10Lh−1 andV=100Lfor the6doses(12.6,34.65,44.69,60.8,83.69and100.37mg).
3.3. Dose-findingsimulation(
nsim
)The function
nsim
simulatesasingleornprospectiveclinical trials.Inthesimulatedtrial,thedoseisescalated stepwise cohortby cohort until the first toxicity response is observed and then the chosen dose-finding method design is applied (two-stage design) as suggestedinUrsinoetal.[8].In additiontotheinput argumentsof
nextDose
,thensim
function hasthe followingadditionalarguments:(i)N
,thetotalsample sizepertrial,(ii)cohort
,thecohortsize,(iii)TR
,thetotalnumberoftrialstobesimulated,(iv)simulatedData
,alistforeachtrial containingprevioussimulateddatasetsasin3.2.1,(v)icon
,avectorcontainingtheindexofrealbloodsamplingthatenablestheusertouseallconcentrationpoints,previouslysimulated,oronlyasubsetofthemand(f)
AUCmethod
,astringnumberspecifyingtheestimation methodforAUC; validchoicesare1fora“compartmental method” (see[8]fordetails)and2fornon-compartmentalmethod(defaults to2).TheestimatedAUCforeachpatientiscomputedinsidethefunctionnsim
,usingonlytheconcentrationsamplesselectedbyicon
.Bydefault,allsimulatedsamplesareused.Similarlytothe
nextDose
function,theuserneedstochooseoneofthedose-findingmodels whichareavailableinthepackage.3.3.1. Demonstration
Asanexample,10trials(i.e.
TR
=10)weresimulatedwith30patients(i.e.N
=30)pertrial,usingthefunctionnsim
.Atthebeginning, thesimulatedData
isdefined(inthiscase,weusethesimulateddatagen.scen
generatedintheSection3.2.1),representingthetrue toxicityprobabilitiesofeachtrial,wheresixdoselevelsareconsidered.Thedoselevelsshouldbeenteredinavector,asfollows:Thetargettoxicityprobability
theta
issetto0.2,meaningthattheMTDisdefinedasthedoseforwhichatmost20%ofdoselimitingtoxicity(DLT)responsesoccur.Forthisexample,thePKTOXmethodisselectedandthe95%CIoftheprobabilityoftoxicityateachdose ischosentobeestimatedandincludedintheresultssincetheinputargument
CI
issettoTRUE
.SinceoursimulationusesStanmodels, wealsoneedtospecifythemodel’soptions,asalist,containingthenumberofchains,howmanyiterationseachchainwilluseandthe numberofwarm-upiterations.Thedefaultchoiceis:After settingtheindexofrealbloodsampling(i.e.
icon
)andenteringthecorrespondingmodel’sinputparameters,wecallthensim
functionasfollowing:
The resultis saved inthe R object,named
simResult
,of a S4 class “dosefinding”.The output can be divided in three parts.The firstpartshowsadatasummary ofthechosendose-findingmodel(PKTOXinthiscase),thesecondparttheStanoptionsandfinallythe dose-findingresultsincludingthepercentageofthedose-allocationandthepercentageoftheMTDselection.Thegeneratedoutputisas follows:Basedontheaboveexample,thenextrecommendeddoselevel is4mgwithapercentageofMTDselectionequalsto60%.
The MTD,toxicity responsesaswell asthedoseescalation for eachtrialcanbeobtainedasfollows:
Thegenericfunction
plot()
canbeusedinordertoillustrate the doseescalation duringthe trialorthe dose-toxicityresponse for each dose level. The main input argument is a “dosefinding”object.The simulation output canbe shown graphicallywiththe command:
where
TR
representsthe numberoftrial(defaults toTR= 1) for whichwe wanttoplotthegraph,CI
indicatesifthesimulation’s resultsincludethe estimated95% oftheprobability oftoxicity or not (defaultstoCI = TRUE
) andask
representstheplotselec- tion index(defaultsto ask= TRUE)showinga selection menuas above:the usershould enter1 tosee thedoseescalation alloca- tion of the selected trial, 2 to create a boxplot of the sampling distribution oftheprobability oftoxicity ateach doseinthe end ofthetrialoverthetotalnumberoftrials,and3toplotthefinal posterior distributions ofthe probability oftoxicity ateach dose (the plotincludes theestimation alongwiththe linesof the95%CI for theselected trial). 0 is the command to exitand 2 isthe defaultchoicefortheinput
ask
.Notethat,ifthesimulation’sre- sults don’t include the 95% CI of probability of toxicity then the selectionmenucontainsonlythefirsttwochoices.Fig.4(A)showsthedoseallocationplotbasedonourexample, wherethenon-toxicity responseisrepresentedasacircleandthe toxicityresponseasacross.Inaddition,Fig.4(B)and4(C)present the output plot choosing, in the menu, 2 and 3, respectively. In Fig. 4(C),the 95% CIandprior probabilities oftoxicity are repre- sentedasdotted anddashedlines,respectively. The reddot-dash lineinthelasttwoFiguresrepresentsthetoxicitythresholdwhich isusedfortheselectionoftheMTD.
Notethat, sincetheBayesianmodelsareimplementedinStan, running simulations can take very long time. Moreover, simula- tionsincludingtheestimationofthe95%credibleintervals(CI)for probability of toxicity at each dose level (i.e.
CI = TRUE
), cantake moretime than excluding them (i.e.
CI = FALSE
). Inthis case,torunthe10trialsincludingthe95%CIofprobabilityoftox- icity,about30minareneededonasingleportablecomputerwith anIntelCorei5.Instead,tosimulateonlytheMTDunderthesame settings,withoutestimatingthe95%CI,about18minarerequired onthesamecomputer.Amoreexpandedcomparisonofthensim
functionandfor1,000simulatedtrials,whichisoftenusedforthe simulation studies in the literature of dose-finding methods, are showninAppendixA.However,wesuggest torun simulationson adedicatedserver.
4. Conclusion
The
dfpk
packageimplementsnovelmethodsfordose-finding phase I clinical trials incorporating PK in the dose-toxicity rela- tionships[8]. In thispackage, each method can be used during a prospectiveadaptive trial,where the doseforthe next cohort of patientsdependsontheoutcomesofthe previouscohorts, inor- dertoestimatetherecommendeddoseforfurtherclinicaltrials.It can alsobe used to performsimulations beforethe beginning of trialinordertostudytherobustnessofthemethodtothediffer- entparameterssettingchoices.Running simulationsisalsouseful tocalibratesome parameters,butittakestime,thereforewesug- gesttorunsimulationsonadedicatedserver.Thepackage isuser-friendly andseveralflexibleinputsare al- lowed:forinstancetheusercangeneratebyher/himselfscenarios (simulated datasets)and pass them on to the function
nsim
, orchangethehyper-prior parametersoftheprior distributions used inthe Bayesian regression.The package will also be updated ac- cordingusersuggestionsandneeds.
5. Discussion
Designing early phase clinical trials is of crucial importance, since all future steps in the clinical development orfailures de- pendonthesefirstresults.Statisticalcomputer programs,suchas
R
,facilitatedesignandthecheckingofperformance throughsim- ulations.Anexampleofexisting Rpackagescanbe foundin[13]. However, to the best of our knowledge, there are no other soft- ware packages available that implement a formal integration of dose-findingandpharmacokinetics.OurRpackagecansupportin- terdisciplinarytrialteamsinimplementinginnovativedose-finding designusingPKinformationinphaseIstudies.Ursino et al. [8] compared a number of dose-finding meth- ods under several scenarios, in order to verify their behaviour andcharacteristics.ThePKCRMmethodbehavesastheCRMalone whentheLisveryhigh.Ontheotherhand,itgivesthesameprob- abilityofcorrect MTD selection(as theCRM) while reducing the probability ofoverdosing, when Lis appropriately chosen.There- fore,thisdesignisrecommendedwheninpreclinicalphasesnon- monitorabletoxicityhasbeenobservedorinsomepediatricstud- ies,whenLcanbeeasilysetfromaliteraturereview.ThePKLOGIT andPKTOX methodsare recommended whenmore precisedose- responsecurveestimationisrequired.ComparedtotheCRMthese methodsareabletobetterestimate theprobabilityoftoxicityas- sociatedwitheachdosealongwithaccurateMTDselection.Inthis way,aricherknowledgecanbetransmittedtosubsequentphases ofclinicaldevelopment.Theothermethodshavesimilarbehaviour toany dose-toxicityregression,andcan be usedfor comparisons insimulations.
The choice of the prior distributions is crucial. In this pack- age, we set as default the prior distributions suggested in [8].
Fig. 4. (A) Plot of the dose escalation (for each patient) in the trial, (B) Boxplot of the sampling distribution of the probability of toxicity at each dose over the total number of trials, and (C) Plot of the posterior distributions of the probability of toxicity at each dose (including the estimation along with the lines of the 95% CI), according to the PKTOX method.
Theseprior hyperparameters were chosen aftersensitivity analy- sistogive goodperformance inmostcases.However, wesuggest settingthepriorhyperparamentersusingpreclinicalinformationor otherexternalpertinentinformationifthisisavailable.
Acknowledgements
We thanks thethree anonymousreviewersandtheassociated editorfor their suggestions. Thisresearch wasconductedas part oftheEuropeanproject,InSPiRe,InnovativeMethodologyforSmall PopulationsResearch.AlltheauthorswerefundedbytheEuropean Union’sSeventhFrameworkProgrammeforresearch,technological developmentand demonstration under grant agreement number FPHEALTH2013–602144.
AppendixA. Simulationtimes
Simulations based on Bayesian methods can be very tedious andtimeconsuming.Therefore,for1,000simulatedtrials,wesug- gesttouseadedicatedserver.Moreover,runninginparallelallthe scenariosandnotsequentiallycanalsoreducethetimeofthesim- ulations.
Table A.1showstheestimatedtimesforconductingthesimu- lationsof10and1,000trials,excludingthe95%credibleintervals, forthemethodsPKTOXandPKCRMunderseveralsettings(i.e.the numberofchainsanditerationsfortheBayesianalgorithm).
Table A.1
Simulation’s estimated times running 10 or 1,0 0 0 trials, in minutes and hours respectively, using different dose-finding methods under several settings for Bayesian algorithm (number of chains and iterations).
Bayesian settings TR = 10 TR = 1,0 0 0
Methods Methods
PKTOX PKCRM PKTOX PKCRM chains = 4, iter = 40 0 0 18 min 10 min ≈ 32 h ≈ 17 h chains = 4, iter = 60 0 0 26 min 14 min ≈ 45 h ≈ 25 h chains = 3, iter = 40 0 0 13 min 7 min ≈ 23 h ≈ 13 h chains = 6, iter = 40 0 0 26 min 14.5 min ≈ 44 h ≈ 24 h
AppendixB.S4classes
Oneofthebigadvantagesof
dfpk
packageisitsflexibleframe-work based on the S4 classes andmethods structure. S4 classes haveallowedustoconstructrich andcomplicateddatarepresen- tationsthatneverthelessseemsimpletotheenduser.Theclassis theabstractdefinition,whileeverytimeweactuallyuseittostore theresultsforagivendataset,wecreateanobjectoftheclass.
Three S4 classes are available, the
dose-class
, thescen-class
and thedosefinding-class
, in order to store, show or plot the corresponding results of the main R functionsnextDose
,sim.data
andnsim
, respectively. You can click on the corresponding help pages as backgroundinformation for the nextsteps.Table B.1
The required slots (i.e. arguments) in the dose class.
N The total number of enrolled patients.
y A binary vector of toxicity outcomes from previous patients; 1 indicates a toxicity, 0 otherwise.
AUCs A vector with the computed AUC values of each patient.
doses A vector with the doses panel.
x A vector with the dose levels assigned to the patients in the trial.
theta The toxicity target.
options A list of Stan model’s options.
newDose The next recommended dose (RD) level; equals to 0 if the trial has stopped, according to the stopping rules.
pstim The estimated mean probabilities of toxicity.
pstimQ1 The 1st quartile of estimated probability of toxicity.
pstimQ3 The 3rd quartile of estimated probability of toxicity.
parameters The Stan model’s estimated parameters.
model A character string to specify the selected dose-finding model used in the method.
Inthissection,abrieflydescriptionoftheaccessibleclassesisshown.
1.
dose-class
The
dose-class
is created to store and present the next recommended dose level in an ongoing trial through the R functionnextDose
.Wecanlookindetailatthestructureoftheclassasfollows:where,
ClassNewDose
isaunionofclasses“numeric”,“logical” and“NULL”.Accordinglytothestructure,the
dose
classconsistsof13slots(i.e.arguments)whicheachone hasaspecifictype. TableB.1givesa briefdefinitionofeachcorrespondingslotsinthedose
class.Anobjectthatcomesfromthe
dose-class
mustcontainalltheaboveslots.Theslotsareaccessedusing@,justascomponentsofa listthatareaccessedusing$.Here,anillustrationofhowtoaccesstheslotsofanobjectisgiven.Wesupposethat
nextD
isanobjectofthedose
class.Forexample,theslotsmodel
andy
canbeobtainedasfollows:where,PKTOX wastheselected dose-findingmodelandthevector (0,0,0,0,0,1,0,0,0,0,1,0,0,0,0)wasthetoxicityoutcome for eachpatientthatareusedinthefunction
nextDose
.Oncetheclassesaredefined,weprobablywanttoperformsomecomputationsonobjects.Inmostcaseswedonotcarehowtheobject isstoredinternally,thecomputer shoulddecidehow toperformthetasks. TheS4wayofreaching thisgoalistousegeneric functions andmethoddispatch.
Basedonouraboveexample,we hypothesisedthat westoredtheoutputofthefunction
nextDose
intheobjectnextD
.Topresenttheresultswecanuseeitherthemethod
show
orBothmethodsgiveaniceandsimplepresentationoftheoutcomethatisstoredintheobject
nextD
.Inanycasewhereuserwantsto changehowtheresultsarepresented,she/hecaneasilydoitbysettingher/hisownshow
ordose
.Similarly,a
plot
genericfunctionisdefinedforthisclassandcanbeeasilyaccessedthroughthecommand:2.
scen-class
Table B.2
The required slots (i.e. arguments) in the scenclass.
PKparameters Subject’s pharmacokinetic’s (PK) parameters from the population distributions defined by the population mean.
nPK The length of time points.
time The sampling time points.
idtr The id number of the corresponding simulated dataset.
N The total sample size per trial.
doses A vector of the doses panel.
preal The prior toxicity probabilities.
limitTox The toxicity threshold.
omegaIIV The inter-individual variability for the clearance and the volume of distribution.
omegaAlpha The patient’s sensitivity parameter.
conc The concentration computed at the PK population values.
concPred The concentration values with proportional errors for each patient at each dose.
tox The toxicity outcome.
tab A summary matrix containing the sampling time points at the first row followed by concPred, parameters and alphaAUC. It used by the simulation function nsim.
parameters The simulated PK parameters of each patient.
alphaAUC A vector with the computed AUC values of each patient.
A
scen
isaS4classtosaveandshowadatasetsimulatedbythefunctionsim.data
.Wecanlookindetailatthestructureofthe classscen
asfollows:Thanks toS4classes,theusercaneasily createhis/herowndatasets.Forexample,he/shecancreateanewobjectforeach simulated trial,namedUserData,andstoreitina
scen-class
byasimilarwayusingthecommandnew
inthefollowingway:andthenadditinalist,alongwiththeothersimulateddatasets.
AdetaileddefinitionofeachslotispresentedintheTableB.2.
Once again, user can accessto the slots andapply thegeneric functionsandmethods in this classby exactlythe same wayas in
dose-class
.Assume thatwe run 10(i.e.TR
=10) simulateddatasetsusing thefunctionsim.data
andsimulatedData
isascen
objectthen:
3.
dosefinding-class
Lastly,athirdS4classisavailableinthepackagedfpk,called
dosefinding
,whichiscreatedtostoreallthedose-findingresultsthat aresimulatedthroughtheRfunctionnsim
.Table B.3
The required slots (i.e. arguments) in the dosefinding class.
pid Patient’s ID provided in the study.
N The total sample size per trial.
time The sampling time points.
doses A vector with the doses panel.
conc The estimated concentration values for each patient at each dose.
p0 The skeleton of CRM for PKCRM.
L The AUC threshold to be set before starting the trial for PKCRM.
nchains The number of chains for the Stan model.
niter The number of iterations for the Stan model.
nadapt The number of warmup iterations for the Stan model.
newDose The next maximum tolerated dose (MTD) if TR = 1 otherwise the percentage of MTD selection for each dose level after all trials starting from dose 0; equals to 0 if the trial has stopped before the end, according to the stopping rules.
MTD A vector containing the next maximum tolerated doses (MTD) of each trial (TR); equals to 0 if the trial has stopped before the end, according to the stopping rules.
MtD The final next maximum tolerated (MTD) dose after all the trials.
theta The toxicity threshold.
doseLevels A vector of dose levels assigned to patients in the trial.
toxicity The estimated toxicity outcome.
AUCs A vector with the computed AUC values of each patient.
TR The total number of trials to be simulated.
preal The prior toxicity probabilities.
pstim The estimated mean probabilities of toxicity.
pstimQ1 The 1st quartile of the estimated probability of toxicity.
pstimQ3 The 3rd quartile of the estimated probability of toxicity.
model A character string to specify the selected dose-finding model used in the method.
seed The seed of the random number generator that is used at the beginning of each trial.
It’sstructureisgivenbelow:
where,21differentslotsareavailable.TableB.3definesallthepossibleslots.
Identicallywiththe
dose
andscen
S4classes,theslotscanpickedusingthe@“operator” andthegenericfunctionsandmethodscan beappliedinthesameway.References
[1] S. Chevret , Statistical Methods for Dose-Finding Experiments of Statistics in Practice, John Wiley and Sons, Chichester, West Sussex, England, 2006 . [2] H. Derendorf , L.J. Lesko , P. Chaikin , W.A. Colburn , P. Lee , R. Miller , R. Pow-
ell , G. Rhodes , D. Stanski , J. Venitz , Pharmacokinetic/pharmacodynamic mod- eling in drug research and development, J. Clin. Pharmacol. 40 (12) (20 0 0) 1399–1418 .
[3] E. Comets , S. Zohar , A survey of the way pharmacokinetics are reported in published phase i clinical trials, with an emphasis on oncology, Clin. Pharma- cokinet. 48 (6) (2009) 387–395 .
[4] F. Bretz , J.C. Pinheiro , M. Branson , Combining multiple comparisons and mod- eling techniques in dose-response studies, Biometrics 61 (3) (2005) 738–748 . [5] S. Piantadosi, G. Liu, Improved designs for dose escalation studies using phar-
macokinetic measurements, Stat. Med. 15 (15) (1996) 1605–1618, doi: 10.1002/
(SICI)1097-0258(19960815)15:15 1605::AID-SIM325 3.0.CO;2-2 .
[6] S. Patterson, S. Francis, M. Ireson, D. Webber, J. Whitehead, A novel Bayesian decision procedure for early-phase dose-finding studies, J. Biopharm. Stat. 9 (4) (1999) 583–597, doi: 10.1081/BIP-100101197 .
[7] J. Whitehead, Y. Zhou, L. Hampson, E. Ledent, A. Pereira, A bayesian approach for dose-escalation in a phase i clinical trial incorporating pharmacodynamic endpoints, J. Biopharm. Stat. 17 (6) (2007) 1117–1129 . PMID: 18027220 doi:
10.1080/10543400701645165 .
[8] M. Ursino, S. Zohar, F. Lentz, C. Alberti, T. Friede, N. Stallard, E. Comets, Dose- finding methods for phase I clinical trials using pharmacokinetics in small pop- ulations, Biom. J. (2017), doi: 10.10 02/bimj.20160 0 084 .
[9] R Core Team, R: a language and environment for statistical computing, in: R Foundation for Statistical Computing, Vienna, Austria, 2013 . ISBN 3-90 0 051- 07-0, http://www.R-project.org/ .
[10] J. Whitehead, S. Patterson, D. Webber, S. Francis, Y. Zhou, Easy-to-implement Bayesian methods for dose-escalation studies in healthy volunteers, Biostatis- tics 2 (1) (2001) 47–61, doi: 10.1093/biostatistics/2.1.47 .
[11] J. O’Quigley , M. Pepe , L. Fisher , Continual reassessment method: a practical de- sign for phase 1 clinical trials in cancer, Biometrics 46 (1) (1990) 33–48 . [12] G. Lestini, C. Dumont, F. Mentré, Influence of the size of cohorts in adaptive
design for nonlinear mixed effects models: an evaluation by simulation for a pharmacokinetic and pharmacodynamic model for a biomarker in oncology, Pharm. Res. 32 (10) (2015) 3159–3169, doi: 10.1007/s11095- 015- 1693- 3 . [13] E. Zhang, H.G. Zhang, Cran task view: clinical trial design, monitoring,
and analysis, 2016, ( https://cran.r-project.org/web/views/ClinicalTrials.html ).
Accessed: 2017-10-22.