powered by
Provide summary statistics from survfit function output
smed(x)
"smed" returns a matrix of 5 columns of
an object returned by "survfit"
n <- 500 event <- runif(n,1, 5) osc<-1*(event<=4) os <- pmin(event,4) fit1<-survival::survfit(survival::Surv(os,osc)~1) smed(fit1)
Run the code above in your browser using DataLab