Estimate Parameters of the Multistate Model Using Clinical Trial Data
Source:R/estimateParams.R
estimateParams.Rd
Estimate Parameters of the Multistate Model Using Clinical Trial Data
Arguments
- data
(
data.frame
)
in the format produced bygetOneClinicalTrial()
.- transition
(
TransitionParameters
object)
specifying the assumed distribution of transition hazards. Initial parameters for optimization can be specified here. Seeexponential_transition()
orweibull_transition()
for details.
Details
This function estimates parameters for transition models using clinical trial data.
The transition
object can be initialized with starting values for parameter estimation.
It uses stats::optim()
to optimize the parameters.
Examples
transition <- exponential_transition(h01 = 2, h02 = 1.4, h12 = 1.6)
simData <- getOneClinicalTrial(
nPat = c(30), transitionByArm = list(transition),
dropout = list(rate = 0.3, time = 12),
accrual = list(param = "time", value = 1)
)
# Initialize transition with desired starting values for optimization:
transition <- exponential_transition(h01 = 1.2, h02 = 1.5, h12 = 1.6)
estimate <- estimateParams(simData, transition)