Provides estimates for the transition probabilities based on LIN estimators, LIN.
transLIN(object, s, t, x, bw="dpik", window="normal", method.weights="NW",
state.names=c("1", "2", "3"), conf=FALSE, n.boot=1000, conf.level=0.95,
method.boot="percentile", ...)
If argument x
is missing or if argument object
doesn't contain a covariate,
an object of class ‘TPmsm’ is returned. There are methods for contour
, image
, print
and plot
.
‘TPmsm’ objects are implemented as a list with elements:
A string indicating the type of estimator used in the computation.
A matrix with transition probability estimates. The rows being the event times and the columns the 5 possible transitions.
A matrix with the lower transition probabilities of the confidence band. The rows being the event times and the columns the 5 possible transitions.
A matrix with the upper transition probabilities of the confidence band. The rows being the event times and the columns the 5 possible transitions.
Vector of times where the transition probabilities are computed.
Start of the time interval.
End of the time interval.
The bandwidth used. If the estimator doesn't require a bandwidth, it's set to NULL
.
A vector of characters giving the states names.
Number of bootstrap samples used in the computation of the confidence band.
Level of confidence used to compute the confidence band.
If argument x
is specified and argument object
contains a covariate,
an object of class ‘TPCmsm’ is returned. There are methods for print
and plot
.
‘TPCmsm’ objects are implemented as a list with elements:
A string indicating the type of estimator used in the computation.
A 3 dimensional array with transition probability estimates. The first dimension being the event times, the second the covariate values and the last one the 5 possible transitions.
A 3 dimensional array with the lower transition probabilities of the confidence band. The first dimension being the event times, the second the covariate values and the last one the 5 possible transitions.
A 3 dimensional array with the upper transition probabilities of the confidence band. The first dimension being the event times, the second the covariate values and the last one the 5 possible transitions.
Vector of times where the transition probabilities are computed.
Vector of covariate values where the conditional transition probabilities are computed.
Start of the time interval.
End of the time interval.
Additional covariate values where the conditional transition probabilities are computed, which may or may not be present in the sample.
The bandwidth used.
A vector of characters giving the states names.
Number of bootstrap samples used in the computation of the confidence band.
Level of confidence used to compute the confidence band.
An object of class ‘survTP’.
The first time for obtaining estimates for the transition probabilities. If missing, 0 will be used.
The second time for obtaining estimates for the transition probabilities.
If missing, the maximum of Stime
will be used.
Covariate values for obtaining estimates for the conditional transition probabilities. If missing, unconditioned transition probabilities will be computed.
A character string indicating a function to compute a kernel density bandwidth. Defaults to “dpik” from package KernSmooth. Alternatively a single numeric value can be specified.
A character string specifying the desired kernel. See details below for possible options. Defaults to “normal” where the gaussian density kernel will be used.
A character string specifying the desired weights method. Possible options are “NW” for the Nadaraya-Watson weights and “LL” for local linear weights. Defaults to “NW”.
A vector of characters giving the state names.
Provides pointwise confidence bands. Defaults to FALSE
.
The number of bootstrap samples. Defaults to 1000 samples.
Level of confidence. Defaults to 0.95 (corresponding to 95%).
The method used to compute bootstrap confidence bands. Possible options are “percentile” and “basic”. Defaults to “percentile”.
Further arguments.
Typically these arguments are passed to the function specified by argument bw
.
Artur Araújo, Javier Roca-Pardiñas and Luís Meira-Machado
If bw="dpik"
then possible options for argument window
are “normal”, “box”, “epanech”, “biweight” or “triweight”.
When argument bw
is numeric then argument window
accepts the same options as when bw="dpik"
plus one of “tricube”, “triangular” or “cosine”.
Araújo A, Meira-Machado L, Roca-Pardiñas J (2014). TPmsm: Estimation of the Transition Probabilities in 3-State Models. Journal of Statistical Software, 62(4), 1-29. tools:::Rd_expr_doi("10.18637/jss.v062.i04")
Meira-Machado L., de Uña-Álvarez J., Datta S. (2011). Conditional Transition Probabilities in a non-Markov Illness-death Model. Discussion Papers in Statistics and Operation Research n 11/03. Department of Statistics and Operations Research, University of Vigo (ISSN: 1888-5756, Deposito Legal VG 1402-2007). https://depc05.webs.uvigo.es/reports/12_05.pdf
Meira Machado L. F., de Uña-Álvarez J., Cadarso-Suárez C. (2006). Nonparametric estimation of transition probabilities in a non-Markov illness-death model. Lifetime Data Anal, 12(3), 325-344. tools:::Rd_expr_doi("10.1007/s10985-006-9009-x")
Davison, A. C., Hinkley, D. V. (1997). Bootstrap Methods and their Application, Chapter 5, Cambridge University Press.
transAJ
,
transIPCW
,
transKMPW
,
transKMW
,
transLS
,
transPAJ
.
# Set the number of threads
nth <- setThreadsTP(2);
# Create survTP object with age as covariate
data(heartTP);
heartTP_obj <- with( heartTP, survTP(time1, event1, Stime, event, age=age) );
# Compute unconditioned transition probabilities
transLIN(object=heartTP_obj, s=33, t=412);
# Compute unconditioned transition probabilities with confidence band
transLIN(object=heartTP_obj, s=33, t=412, conf=TRUE, conf.level=0.9,
method.boot="basic");
# Compute conditional transition probabilities
transLIN(object=heartTP_obj, s=33, t=412, x=0);
# Compute conditional transition probabilities with confidence band
transLIN(object=heartTP_obj, s=33, t=412, x=0, conf=TRUE, conf.level=0.95,
n.boot=100, method.boot="percentile");
# Restore the number of threads
setThreadsTP(nth);
Run the code above in your browser using DataLab