MC.sim: Markov Chain simulation

Description Usage Arguments Value Author(s) Examples

Description

Simulate the stationary discrete Markov Chain distribution.

Usage

1
MC.sim(p, k, n)

Arguments

p

is the probability matrix for the Markov Chain. p has to be a n x n matrix.

k

is the initial state.

n

is number af steps to be simulated.

Value

Returns the stationary probabilities for each state.

Author(s)

Tobias Mortensen
Department of mathematics and computer science (IMADA)
University of southern Denmark, Odense
tomor14@student.sdu.dk

Examples

1
MC.sim(p=matrix(c(.6,.4,.4,.6), ncol=2), k=2, n=1000)

tomor14/Examst522 documentation built on May 31, 2019, 6:20 p.m.