# Set the number of threads
nth <- setThreadsTP(2);
# Create survTP object
data(heartTP);
heartTP_obj <- with( heartTP, survTP(time1, event1, Stime, event) );
# Compute transition probabilities
transPAJ(object=heartTP_obj, s=33, t=412);
# Compute transition probabilities with confidence band
transPAJ(object=heartTP_obj, s=33, t=412, conf=TRUE, conf.level=0.9,
method.boot="percentile");
# Restore the number of threads
setThreadsTP(nth);
Run the code above in your browser using DataLab