mc: Markov chain definition

Description Usage Arguments Examples

Description

Construct and initialize either a continuous or discrete markov chain. Input will be assumed discrete unless qidef is defined. Input will be assumed finite unless pijdef is a function.

Usage

1
mc(pijdef = NULL, qidef = NULL)

Arguments

pijdef

is either a square finite transition matrix or a function(i, j) defining a (potentially) infinite transition matrix.

qidef

is a vector containing the holding-time of each state in a continuous markov chain or a function(i, j) defining a (potentially) infinite holding-time vector.

Examples

1
2
3
4
5
6
7
pijdef = matrix(rep(0,9), nrow=3)
pijdef[1,1] <- 0.5
pijdef[1,2] <- 0.5
pijdef[2,3] <- 0.5
pijdef[2,1] <- 0.5
pijdef[3,1] <- 1
markov_chain = mc(pijdef)

drlevy/ECS256-HW1 documentation built on May 15, 2019, 2:21 p.m.