Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Would prettify be updated to be applied to objects of class "crr"? #44

Open
jlabordenavas opened this issue Jul 18, 2019 · 1 comment
Open

Comments

@jlabordenavas
Copy link

This package is very useful, however the competing risks regression class (crr {cmprsk}) is not applicable unfortunately. Any chance this will get supported in the future?

@hofnerb
Copy link
Owner

hofnerb commented Aug 5, 2019

dear @jlabordenavas, unfortunately I currently do not have the time to implement this feature. However, I am more than happy to support you in implementing it. Essentially, all you need is a results table derived from the model summary. See https://github.com/hofnerb/papeR/blob/master/R/prettify.R for examples.

Actually, it should be pretty straight forward. One can extract all relevant details as follows:

### load package and fit some model

library("cmprsk")
# simulated data to test 
set.seed(10)
ftime <- rexp(200)
fstatus <- sample(0:2,200,replace=TRUE)
cov <- matrix(runif(600),nrow=200)
dimnames(cov)[[2]] <- c('x1','x2','x3')
print(z <- crr(ftime,fstatus,cov))
x <- summary(z)

### this should be all what is needed
x$coef
x$conf.int

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants