# Calculate crude initial values for transition intensities

### Description

Calculates crude initial values for transition intensities by assuming that the data represent the exact transition times of the Markov process.

### Usage

1 |

### Arguments

`formula` |
A formula giving the vectors containing the observed states and the corresponding observation times. For example,
Observed states should be in the set |

`subject` |
Vector of subject identification numbers for the data
specified by |

`qmatrix` |
Matrix of indicators for the allowed
transitions. An initial value will be estimated for each
value of qmatrix that is greater than zero. Transitions are
taken as disallowed for each entry of |

`data` |
An optional data frame in which the variables represented
by |

`censor` |
A state, or vector of states, which indicates
censoring. See |

`censor.states` |
Specifies the underlying states which censored observations can
represent. See |

### Details

Suppose we want a crude estimate of the transition intensity *q_rs* from state *r* to
state *s*. If we observe *n_rs* transitions from state *r* to state *s*, and a
total of *n_r* transitions from state *r*, then *q_rs / q_rr* can be estimated by *n_rs / n_r*. Then, given a total of *T_r* years
spent in state *r*, the mean sojourn time *1 / q_rr* can be estimated as *T_r / n_r*.
Thus, *n_rs / T_r* is a crude estimate of
*q_rs*.

If the data do represent the exact transition times of the Markov process, then these are the exact maximum likelihood estimates.

Observed transitions which are incompatible with the given
`qmatrix`

are ignored. Censored states are ignored.

### Value

The estimated transition intensity matrix. This can be used as
the `qmatrix`

argument to `msm`

.

### Author(s)

C. H. Jackson chris.jackson@mrc-bsu.cam.ac.uk

### See Also

`statetable.msm`

### Examples

1 2 3 4 5 |

Want to suggest features or report bugs for rdrr.io? Use the GitHub issue tracker. Vote for new features on Trello.