Ensurep

From Eigenvector Documentation Wiki
Jump to: navigation, search

Contents

Purpose

Verifies that input contains only probabilities in [0,1].

Synopsis

prob = ensurep(x)

Description

The input is a real (x) and the output is (prob):

   If x > 1, then prob = 1.
   If x < 0, then prob = 0.
   If x imaginary, inf, or NaN, then prob = NaN.

Examples

prob = ensurep(prob);

See Also

ck_function

Views
Personal tools