npSurv2 | R Documentation |
Computes the survival function for bivariate failure time data using one of three possible estimators, including Dabrowska, Volterra and Prentice-Cai estimators. Optionally (bootstrap) confidence intervals for the survival function may also be computed.
npSurv2(
Y1,
Y2,
Delta1,
Delta2,
newT1 = NULL,
newT2 = NULL,
estimator = c("dabrowska", "volterra", "prentice-cai"),
conf.int = FALSE,
R = 1000,
...
)
Y1, Y2 |
Vectors of event times (continuous). |
Delta1, Delta2 |
Vectors of censoring indicators (1=event, 0=censored). |
newT1, newT2 |
Optional vectors of times at which to estimate the survival function (which do not need to be subsets of Y1/Y2). Defaults to the unique values in Y1/Y2 if not specified. |
estimator |
Which estimator of the survival function should be used. Possible values include "dabrowska", "volterra", and "prentice-cai". Defaults to "dabrowska". |
conf.int |
Should bootstrap confidence intervals be computed? |
R |
Number of bootstrap replicates. This argument is passed to the boot function. Defaults to 1000. Ignored if conf.int is FALSE. |
... |
Additional arguments to the boot function. |
A list containing the following elements:
Unique uncensored Y1 values
Unique uncensored Y2 values
Estimated bivariate survival function (computed at T1, T2)
Lower 95% confidence bounds for Fhat
Upper 95% confidence bounds for Fhat
Estimated marginal survival function for T1 (computed at newT1)
Lower 95% confidence bounds for Fmarg1
Upper 95% confidence bounds for Fmarg1
Estimated marginal survival function for T2 (computed at newT2)
Lower 95% confidence bounds for Fmarg2
Upper 95% confidence bounds for Fmarg2
Estimated survival function (computed at newT1, newT2)
Lower 95% confidence bounds for F.est
Upper 95% confidence bounds for F.est
Estimated cross ratio (computed at T1, T2)
Estimated Kendall\'s tau (computed at T1, T2)
Estimated cross ratio (computed at newT1, newT2)
Estimated Kendall\'s tau (computed at newT1, newT2)
If conf.int is TRUE, confidence intervals will be computed using the boot function in the boot package. Currently only 95% confidence intervals computed using the percentile method are implemented. If conf.int is FALSE, confidence intervals will not be computed, and confidence bounds will not be returned in the output.
Prentice, R., Zhao, S. "Nonparametric estimation of the multivariate survivor function: the multivariate Kaplan–Meier estimator", Lifetime Data Analysis (2018) 24:3-27. Prentice, R., Zhao, S. "The statistical analysis of multivariate failure time data: A marginal modeling approach", CRC Press (2019). pp. 52-60.
boot
x <- genClayton2(100, 0, 1, 1, 2, 2)
x.npSurv2 <- npSurv2(x$Y1, x$Y2, x$Delta1, x$Delta2)
x.npSurv2.ci <- npSurv2(x$Y1, x$Y2, x$Delta1, x$Delta2,
conf.int=TRUE)
x.npSurv2.volt <- npSurv2(x$Y1, x$Y2, x$Delta1, x$Delta2,
estimator="volterra")
x.npSurv2.t <- npSurv2(x$Y1, x$Y2, x$Delta1, x$Delta2,
newT1=-1*log(c(0.55, 0.7, 0.7, 0.85, 0.85, 0.85)),
newT2=-1*log(c(0.55, 0.55, 0.7, 0.55, 0.7, 0.85)))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.