Ali Roghani
Ali Roghani

Reputation: 509

Create a column includes all confidence intervals

I have a code like that :

library("survival")
library("survminer")

data("lung")

res.cox <- coxph(Surv(time, status) ~ sex, data = lung)

x<-confint(res.cox)

I am looking to get all the confidence intervals, not only the upper and lower bands. So I will have a confidence interval for each participant (N=228). Actually, I need to plot the confidence intervals with their distributions.

Upvotes: 0

Views: 137

Answers (1)

Ali Roghani
Ali Roghani

Reputation: 509

If you want it to assign it to the data is :


lung$CI<- predict(res.cox)

Upvotes: 0

Related Questions