penetrance_c: Estimating Penetrances for competing risk models and...

View source: R/penetrance_c.R

penetrance_cR Documentation

Estimating Penetrances for competing risk models and confidence intervals

Description

Estimates the cumulative disease risks (penetrances) and confidence intervals for the event of interest in the presence of competing event given fixed values of covariates based on the fitted competing risk model.

Usage

  penetrance_c(fit, event = 1, fixed, age, CI = TRUE, MC = 100)

Arguments

fit

An object class of 'penmodel_c', a fitted model by penmodel_c function.

event

Event of interest (either 1 or 2) for penetrance estimation. Default value is 1.

fixed

list of vectors of fixed values of the covariates for both events used for penetrance calculation.

age

Vector of ages used for penetrance calculation.

CI

Logical; if TRUE, the 95% confidence interval will be obtained using a Monte-Carlo method, otherwise no confidence interval will be provided. Default is TRUE.

MC

Number of simulated samples used to calculate confidence intervals with a Monte-Carlo method. If MC=0, no confidence intervals will be calculated. Default value is 100.

Details

The cause-specific hazard for event j is specified as: hj(t|x) = h0j(t) exp(βj *xj), where h0j(t) is the baseline hazards function for event j, xj is the vector of covariates associated with event j and βj is the vector of corresponding regression coefficients, j = 1, 2.

The penetrance function for event j in the presence of competing risks based on cause-specific hazards (with no frailties assumed) model is defined as the probability of developing an event of interest by age t given fixed values of covariates x in the following form: P(T < t, d = j |x) = ∫t0t hj(u|xj)exp(-H1(u|x1)-H2(u|x2))du, where t0 is the minimum age of onset, d is the type of event which takes (j = 1, 2).

The shared frailty competing risks model is: hj(t|zj, x) = zj*h0j(t) exp(βj *xj), where zj is the shared frailty for event j within families whose distribution is specified by frailty.dist.

The penetrance function for event j from the shared frailty competing risks model is obtained by integrating over the frailty distribution of G(z1, z2), P(T < t, d = j | x) = ∫t0t ∫ ∫ hj(u|xj, zj) exp(-H1(u|x1 zj)-H2(u|x2, zj)) dG(z1 dz2)du, where t0 is the minimum age of onset, d is the type of event which takes (j = 1, 2).

See Choi et al. (2021) for more details about the penetrance functions.

Calculations of standard errors of the penetrance estimates and 95% confidence intervals (CIs) for the penetrance at a given age are based on Monte-Carlo simulations of the estimated penetrance model. A multivariate normal distribution is assumed for the parameter estimates, and MC = n sets of the parameters are generated from the multivariate normal distribution with the parameter estimates and their variance-covariance matrix. For each simulated set, a penetrance estimate is calculated at a given age by substituting the simulated parameters into the penetrance function.

The standard error of the penetrance estimate at a given age is calculated by the standard deviation of penetrance estimates obtained from n simulations.

The 95% CI for the penetrance at a given age is calculated using the 2.5th and 97.5th percentiles of the penetrance estimates obtained from n simulations.

Value

Returns the following values:

age

Ages at which the penetrances are calculated.

penetrance

Penetrance estimates at given ages.

lower

Lower limit of the 95% confidence interval; simulation-based 2.5th percentile of the penetrance estimates.

upper

Upper limit of the 95% confidence interval; simulation-based 97.5th percentile of the penetrance estimates.

se

Simulation-based standard errors of the penetrance estimates.

Author(s)

Yun-Hee Choi

References

Choi, Y.-H., Jung, H., Buys, S., Daly, M., John, E.M., Hopper, J., Andrulis, I., Terry, M.B., Briollais, L. (2021) A Competing Risks Model with Binary Time Varying Covariates for Estimation of Breast Cancer Risks in BRCA1 Families, Statistical Methods in Medical Research 30 (9), 2165-2183. https://doi.org/10.1177/09622802211008945.

Choi, Y.-H., Briollais, L., He, W. and Kopciuk, K. (2021) FamEvent: An R Package for Generating and Modeling Time-to-Event Data in Family Designs, Journal of Statistical Software 97 (7), 1-30. doi:10.18637/jss.v097.i07

See Also

simfam_c, penmodel_c

Examples

## Not run: 
set.seed(4321)
fam2 <- simfam_c(N.fam = 200, design = "pop+", variation = "frailty", competing = TRUE,
                base.dist = "Weibull", frailty.dist = "cgamma", depend=c(2, 2, 2), 
                base.parms = list(c(0.01, 3), c(0.01, 3)), 
                vbeta = list(c(-1.13, 2.35), c(-1, 2)), allelefreq = 0.02)

fit2 <- penmodel_c(Surv(time, status==1) ~ gender + mgene, 
                   Surv(time, status==2) ~ gender + mgene, 
                   cluster = "famID", gvar = "mgene", frailty.dist = "cgamma",
                   parms = list(c(0.01, 3, -1, 2.3), c(0.01, 3, -1, 2), c(2, 2, 2)), 
                   data = fam2, design = "pop+", base.dist = "Weibull", 
                   agemin = NULL, robust = TRUE)

# Compute penetrance estimates for event 1 for male carriers at age 40, 50, 60, 70 and
# their 95
 
penetrance_c(fit2, event = 1, fixed = list(c(1,1), c(1,1)), 
             age = c(40, 50, 60, 70), CI = TRUE, MC = 200)

## End(Not run)

FamEvent documentation built on Nov. 17, 2022, 5:06 p.m.