Biograph.mvna: Converts Biograph object to input data for mvna package

Description Usage Arguments Details Value Note Author(s) References Examples

Description

Converts Biograph object to long format used as input data in mvna package.

Usage

1

Arguments

Bdata

Biograph object

Details

The function performs four operations on data in Biograph format:

a. It checks whether intrastate transitions are omitted, i.e. that the diagonal elements are zero. If that is not the case, then it calls the Remove.intrastate function to remove the intrastate moves.

b. It calls the Parameters function to determine the parameters associated with the Biograph object with diagonal elements removed.

c. It calls the Biograph.long function to create an object having the data in long format.

d. It adds to the data frame the variables entry and exit and it changes the variable name of the subject identification number from ID to id.

Value

D

Data frame of class "mvna" (only variables that are required)

D.cov

Data in mvna format, including covariates and some other variables

par

Object produced by Parameters function, including the object trans_possible: possible transitions

cens

Character string denoting censoring (it is "cens")

Note

Function Biograph.mvna uses the functions Extract, remove.intrastate and Biograph.long

Author(s)

Frans Willekens

References

Allignol, A., J. Beyersmann and M. Schumacher (2008) mvna: An R package for the Nelson-Aalen estimator in multistate models. R Newsletter, 8(2):48-50

Allignol, A., M. Schumacher and J. Beyersmann (2011). Empirical transition matrix of multistate models: the etm package. Journal of Statistical Software, 38(4), 15 pp.

Examples

1
2
3
4
5
6
7
8
  data(GLHS)
  D <- Biograph.mvna (GLHS)
  # Run mvna:
  require (mvna)
  zz <- attr(D$D,"param")$namstates
  zzz <- attr(D$D,"param")$trans_possible
  na <- mvna(data=D$D,state.names=zz,tra=zzz,cens.name=D$cens)
  

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