Date are generated from the one-step joint frailty-copula model, under the Claton
copula function (see jointSurroCopPenal
for more details)
jointSurrCopSimul(
n.obs = 600,
n.trial = 30,
prop.cens = 0,
cens.adm = 549,
alpha = 1.5,
gamma = 2.5,
sigma.s = 0.7,
sigma.t = 0.7,
cor = 0.9,
betas = c(-1.25, 0.5),
betat = c(-1.25, 0.5),
frailt.base = 1,
lambda.S = 1.3,
nu.S = 0.0025,
lambda.T = 1.1,
nu.T = 0.0025,
ver = 2,
typeOf = 1,
equi.subj.trial = 1,
equi.subj.trt = 1,
prop.subj.trial = NULL,
prop.subj.trt = NULL,
full.data = 0,
random.generator = 1,
random = 0,
random.nb.sim = 0,
seed = 0,
nb.reject.data = 0,
thetacopule = 6,
filter.surr = c(1, 1),
filter.true = c(1, 1),
covar.names = "trt",
pfs = 0
)
Number of considered subjects. The default is 600
.
Number of considered trials. The default is 30
.
A value between 0
and 1
, 1-prop.cens
is the minimum proportion of
people who are randomly censored.
Represents the quantile to use for generating the random censorship time. In this case, the censorship
time follows a uniform distribution in 1
and (prop.cens)ieme
percentile of the
generated death times. If this argument is set to 0
, the fix censorship is considered.
The default is 0
.
Censorship time. If argument prop.cens
is set to 0
, it represents
the administrative censorship time, else it represents the fix censoring time. The default is 549
,
for about 40%
of fix censored subjects.
Fixed value for \(\alpha\). The default is 1.5
.
Fixed value for \(\gamma\). The default is 2.5
.
Fixed value for
\(\sigma\). The default is 0.7
.
Fixed value for
\(\sigma\). The default is 0.7
.
Desired level of correlation between v and v.
R
= cor .
The default is 0.8
.
Vector of the fixed effects for \(\beta\).
The size must be equal to ver
The default is c(-1.25,0.5)
.
Vector of the fixed effects for \(\beta\).
The size must be equal to ver
The default is c(-1.25,0.5)
.
Considered heterogeneity on the baseline risk (1)
or not (0)
.
The default is 1
.
Desired scale parameter for the Weibull
distribution associated with the Surrogate
endpoint. The default is 1.8.
Desired shape parameter for the Weibull
distribution associated with the Surrogate
endpoint. The default is 0.0045.
Desired scale parameter for the Weibull
distribution associated with the True endpoint.
The default is 3.
Desired shape parameter for the Weibull
distribution associated with the True endpoint.
The default is 0.0025.
Number of covariates. The mandatory covariate is the treatment arm. The default is 2
.
Type of joint model used for data generation: 0 = classical joint model
with a shared individual frailty effect (Rondeau, 2007), 1 = joint frailty-copula model with shared frailty
effects u
and two correlated random effects treatment-by-trial interaction
(v, v),
see jointSurroCopPenal
.
A binary variable that indicates if the same proportion of subjects should be included per trial (1)
or not (0). If 0, the proportions of subject per trial are required with parameter prop.subj.trial
.
A binary variable that indicates if the same proportion of subjects is randomized per trial (1)
or not (0). If 0, the proportions of subject per trial are required with parameter prop.subj.trt
.
The proportions of subjects per trial. Requires if equi.subj.trial = 0
.
The proportions of randomized subject per trial. Requires if equi.subj.trt = 0
.
Specified if you want the function to return the full dataset (1), including the random effects,
or the restictive dataset (0) with at least 7
columns as required for the function jointSurroCopPenal
.
The random number generator used by the Fortran compiler,
1
for the intrinsec subroutine Random_number
and 2
for the
subroutine uniran()
. The default is 1
.
A binary that says if we reset the random number generation with a different environment
at each call (1)
or not (0)
. If it is set to 1
, we use the computer clock
as seed. In the last case, it is not possible to reproduce the generated datasets.
The default is 0
. Required if random.generator
is set to 1.
required if random.generator
is set to 1, and if random
is set to 1.
The seed to use for data (or samples) generation. Required if the argument random.generator
is set to 1.
Must be a positive value. If negative, the program do not account for seed. The default is 0
.
Number of generation to reject before the considered dataset. This parameter is required
when data generation is for simulation. With a fixed parameter and random.generator
set to 1,
all ganerated data are the same. By varying this parameter, different datasets are obtained during data generations. The default value is 0,
in the event of one dataset.
The desired value for the copula parameter. The default is 6
.
Vector of size the number of covariates, with the i-th element that indicates if the hazard for surrogate is adjusted on the i-th covariate (code 1) or not (code 0). By default, 2 covariates are considered.
Vector defines as filter.surr
, for the true endpoint. filter.true
and filter.surr
should have the same size
Vector of the names of covariables. By default it contains "trt" for the tratment arm. Should contains the names of all covarites wished in the generated dataset.
Is used to specify if the time to progression should be censored by the death time (0) or not (1). The default is 0. In the event with pfs set to 1, death is included in the surrogate endpoint as in the definition of PFS or DFS.
This function returns if the parameter full.data
is set to 0, a data.frame
with columns :
A numeric, that represents the patient's identifier, must be unique;
A numeric, that represents the trial in which each patient was randomized;
The treatment indicator for each patient, with 1 = treated, 0 = untreated;
The follow up time associated with the surrogate endpoint;
The event indicator associated with the surrogate endpoint. Normally 0 = no event, 1 = event;
The follow up time associated with the true endpoint;
The event indicator associated with the true endpoint. Normally 0 = no event, 1 = event;
u
, latex\(v_{S_i}\) and
\(v_{T_i}\)htmlv
and
v
are returned.
We just considered in this generation, the Gaussian random effects. If the parameter full.data
is set to 1,
this function return a list containning severals parameters, including the generated random effects.
The desired individual level correlation (Kendall's \(\tau\)) depend on the values of the copula parameter
\(\theta\), given that \(\tau = \theta /(\theta + 2)\) under the clayton copula model.
Rondeau V., Mathoulin-Pelissier S., Jacqmin-Gadda H., Brouste V. and Soubeyran P. (2007). Joint frailty models for recurring events and death using maximum penalized likelihood estimation: application on cancer events. Biostatistics 8(4), 708-721.
Sofeu, C. L., Emura, T., and Rondeau, V. (2020). A joint frailty-copula model for meta-analytic
validation of failure time surrogate endpoints in clinical trials. Under review
# NOT RUN {
# }
# NOT RUN {
# dataset with 2 covariates and fixed censorship
data.sim <- jointSurrCopSimul(n.obs=600, n.trial = 30, prop.cens = 0, cens.adm=549,
alpha = 1.5, gamma = 2.5, sigma.s = 0.7, sigma.t = 0.7,
cor = 0.8, betas = c(-1.25, 0.5), betat = c(-1.25, 0.5),
full.data = 0, random.generator = 1,ver = 2, covar.names = "trt",
nb.reject.data = 0, thetacopule = 6, filter.surr = c(1,1),
filter.true = c(1,1), seed = 0)
#dataset with 2 covariates and random censorship
data.sim2 <- jointSurrCopSimul(n.obs=600, n.trial = 30, prop.cens = 0.75,
cens.adm = 549, alpha = 1.5, gamma = 2.5, sigma.s = 0.7,
sigma.t = 0.7, cor = 0.8, betas = c(-1.25, 0.5),
betat = c(-1.25, 0.5), full.data = 0, random.generator = 1,
ver = 2, covar.names = "trt", nb.reject.data = 0, thetacopule = 6,
filter.surr = c(1,1), filter.true = c(1,1), seed = 0)
# }
Run the code above in your browser using DataLab