Plot interactions for survival analysis

I would like to plot the interaction effects of a Cox model derived from the survival package. How to do that? I am using the lung dataset shipped with the package as an example:

lung$sex <- factor(lung$sex, levels = 1:2, labels = c("male", "female"))
lung <- with(lung, lung[complete.cases(time, status, sex, age, ph.karno), ])
cph <- coxph(formula = Surv(time, status)~ (age + sex + ph.karno)^2, data=lung)

How to plot the interactions age:sexfemale , age:ph.karno , and sexfemale:ph.karno ? Thank you for any help!

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.