Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

prepare.los.data

Prepare the data for clos


Description

Prepare data to be passed to clos() in package etm.

Usage

prepare.los.data(x)

Arguments

x

data.frame of the form data.frame(id, j.01, j.02, j.03, j.12, j.13, cens):

id:

id (patient id, admision id)

j.01:

observed time for jump from 0 to 1

j.02:

observed time for jump from 0 to 2

j.03:

observed time for jump from 0 to 3

j.12:

observed time for jump from 1 to 2

j.13:

observed time for jump from 1 to 3

cens:

censoring time (either in initial or intermediate state)

Value

a data.frame of the form data.frame(id, from, to, time, oid):

id:

id (patient id, admision id)

from:

the state from where a transition occurs

to:

the state to which a transition occurs

time:

time of the transition

oid:

the observation id

Author(s)

Matthias Wangler

See Also

Examples

data(los.data)
my.observ <- prepare.los.data(x=los.data)

etm

Empirical Transition Matrix

v1.1.1
MIT + file LICENSE
Authors
Mark Clements [aut, cre], Arthur Allignol [aut]
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.