Skip to contents

Converts a directed acyclic graph (DAG) into it's equivalence class corresponding to a completed partially directed acyclic graph (CPDAG).

Usage

DAGtoCPDAG(x)

Arguments

x

A matrix, cia_chain, or cia_chains object. When it is a chain(s) object the state must be an adjacency matrix.

Value

x Returns same object type converted to a CPDAG.

Examples

dag <- UniformlySampleDAG(LETTERS[1:3])
DAGtoCPDAG(dag)
#>   A B C
#> A 0 1 1
#> B 1 0 0
#> C 1 0 0