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

View source: R/probtrans_ebmstate.R

Compute subject-specific transition probabilities using convolution.

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

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

`cumhaz` |
An |

`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) |

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.

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

.

Rui Costa & Moritz Gerstung

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")
``` |

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.