stulacy / multistateutils

Utility funtions for parametric multi-state modelling in R
GNU General Public License v3.0
6 stars 2 forks source link

output of msprep2 is not class msdata #8

Closed sdaza closed 4 years ago

sdaza commented 5 years ago

Thanks for your great package.

The output of the function msprep2 is not class msdata so cannot be directly used as input for functions such as events (mstate package).

Just adding like the code below will solve the problem:

output = as.data.frame(output)
attr(output, "trans") = tmat
class(output) = c("msdata","data.frame")
stulacy commented 5 years ago

Thanks for bringing this to my attention, I'll have a look at this and see if it's a feature worth adding.

stulacy commented 4 years ago

This feature has been added in release 1.2.3 which is now on CRAN.