probtrans_ebmstate: Compute subject-specific transition probabilities using...

Description Usage Arguments Details Value Author(s) See Also Examples

View source: R/probtrans_ebmstate.R

Description

Compute subject-specific transition probabilities using convolution.

Usage

1
2
3
4
5
6
7
probtrans_ebmstate(
  initial_state,
  cumhaz,
  model,
  max_time = NULL,
  nr_steps = 10000
)

Arguments

initial_state

The present function estimates transition probabilities from the state given in this argument.

cumhaz

An msfit object created by running mstate or mstate_generic.

model

Either 'Markov' or 'semiMarkov'. See details.

max_time

The maximum time for which transition probabilities are estimated.

nr_steps

The number of steps in the convolution algorithm (larger increases precision but makes it slower)

Details

The Markov model is a non-homogeneous Markov model in which the transition hazard rates depend only on time since the initiating event. The semi-Markov model has a single time scale: the sojourn time in the current state. This is sometimes called homogeneous semi-Markov model.

The algorithm behind probtrans_ebmstate is based on the convolution of density and survival functions and is suitable for processes with a tree-like transition structure only.

Value

An object of class 'probtrans'. See the 'value' section in the help page of mstate::probtrans.

Author(s)

Rui Costa & Moritz Gerstung

See Also

probtrans;

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
# Compute transition probabilities
# from an object with (pre-estimated) 
# cumulative hazard rates.

#load object with estimated
#cumulative hazard rates 
data("msfit_object_sample")

#compute transition probabilities
probtrans_object<-probtrans_ebmstate("health",
   msfit_object_sample,"Markov")

ebmstate documentation built on Jan. 6, 2021, 1:09 a.m.