Biograph.msm: Biograph to msm format

Description Usage Arguments Value Author(s) References Examples

View source: R/Biograph.msm.R

Description

Converts Biograph object to input data for msm package (long format)

Usage

1
Biograph.msm(Bdata)

Arguments

Bdata

Biography object

Value

Data frame with data in msm format

Author(s)

Frans Willekens

References

Jackson, C. (2011). Multi-state models for panel data: the msm package for R. Journal of Statistical Software, 38(8), 28 pp.

Jackson, C. (2013). msm: Multi-state Markov and hidden Markov models in continuous time. Available at the CRAN repository.

Examples

1
2
3
4
5
 data(GLHS)
 D <- Biograph.msm (GLHS)
 # Function statetable.msm of msm package
 require(msm)
 statetable.msm(state,ID,data=D)

Example output

[1] . . . . .  running reshape  . . . . . 
[1]  . . .  . Adjusting long format  . . . . 
Loading required package: msm
    to
from   1   2
   1  59 323
   2 181 419

Biograph documentation built on May 1, 2019, 8:48 p.m.