2013-02-22 43 views

回答

0

survAsurvB一個可能的解決方案爲survdiff -objects:

interval <- 0:2500 
# choose a different time interval if you want 

sumA <- summary(survA, time = interval) 
sumB <- summary(survB, time = interval) 

both <- data.frame(time = interval, A = sumA$surv, B = sumB$surv) 

both$diff <- both$B - both$A 
# or both$diff <- both$A - both$B 

plot(x = both$time, y = both$diff, type = "line")