Learn R Programming

fHMM (version 1.1.1)

is_tpm: Check for transition probability matrix

Description

This function checks if x is a tpm (transition probability matrix).

Usage

is_tpm(x)

Value

Either TRUE or FALSE.

Arguments

x

A matrix.

Examples

Run this code
if (FALSE) {
is_tpm(diag(2))
is_tpm(matrix(1, 2, 2))
}

Run the code above in your browser using DataLab