compute_order_BF: Compute the Bayes factor comparing a second-order Markov...

View source: R/order_selection.r

compute_order_BFR Documentation

Compute the Bayes factor comparing a second-order Markov model to a first-order one.

Description

Compute the Bayes factor comparing a second-order Markov model to a first-order one.

Usage

compute_order_BF(seq)

Arguments

seq

a vector containing observations from an stochastic process.

Value

the approximate Bayes factor comparing a second- to a first-order Markov chain model for seq.

Examples

X <- rbinom(n = 1E5, size = 1, prob = 0.8)
compute_order_BF(X)

maxbiostat/BinaryMarkovChains documentation built on Dec. 11, 2023, 4:29 a.m.