is.valid.bn: Check validity.

Description Usage Arguments Value See Also Examples

View source: R/class.R

Description

Checks whether the supplied 'bn is valid. Tests that the parents are sorted correctly, are of storage.mode() == "integer". Additionally checks that the supplied bn is acyclic.

Usage

1
2
  ## S3 method for class 'bn'
 is.valid(x)

Arguments

x

A object of class 'bn'

Value

A logical of length 1 indicating whether x is a valid 'bn' object

See Also

is.valid.parental

Examples

1
2
x <- bn(c(), 1, 2)
is.valid(x)

rjbgoudie/parental documentation built on May 27, 2019, 9:11 a.m.