expmat | R Documentation |
This is a wrapper around msm::MatrixExp()
that computes the exponential
of multiple square matrices.
expmat(x, t = 1, ...)
x |
An array of matrices. |
t |
An optional scaling factor for |
... |
Arguments to pass to |
This function is most useful when exponentiating transition intensity
matrices to produce transition probability matrices. To create transition
probability matrices for discrete time state transition models with annual
cycles, set t=1
. An array of matrices is returned which can be used
to create the value
element of a tparams_transprobs
object. See
qmatrix()
for an example.
Returns an array of exponentiated matrices. If length(t) > 1
, then
length(t)
arrays are returned for each element in x
.
qmatrix.msm()
, qmatrix.data.table()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.