triangulate {jti}R Documentation

Triangulate a Bayesian network

Description

Given a list of CPTs, this function finds a triangulation

Usage

triangulate(
  x,
  root_node = "",
  joint_vars = NULL,
  tri = "min_fill",
  pmf_evidence = NULL,
  alpha = NULL,
  perm = FALSE,
  mpd_based = FALSE
)

## S3 method for class 'cpt_list'
triangulate(
  x,
  root_node = "",
  joint_vars = NULL,
  tri = "min_fill",
  pmf_evidence = NULL,
  alpha = NULL,
  perm = FALSE,
  mpd_based = FALSE
)

Arguments

x

An object returned from cpt_list (baeysian network) or pot_list (decomposable markov random field)

root_node

A node for which we require it to live in the root clique (the first clique).

joint_vars

A vector of variables for which we require them to be in the same clique. Edges between all these variables are added to the moralized graph.

tri

The optimization strategy used for triangulation if x originates from a Baeysian network. One of

  • 'min_fill'

  • 'min_rfill'

  • 'min_sp'

  • 'min_ssp'

  • 'min_lsp'

  • 'min_lssp'

  • 'min_elsp'

  • 'min_elssp'

  • 'min_nei'

  • 'minimal'

  • 'alpha'

pmf_evidence

A named vector of frequencies of the expected missingness of a variable. Variables with frequencies of 1 can be neglected; these are inferrred. A value of 0.25 means, that the given variable is expected to be missing (it is not a evidence node) in one fourth of the future cases. Relevant for tri methods 'min_elsp' and 'min_elssp'.

alpha

Character vector. A permutation of the nodes in the graph. It specifies a user-supplied eliminination ordering for triangulation of the moral graph.

perm

Logical. If TRUE the moral graph is permuted

mpd_based

Logical. True if the triangulation should be performed on a maximal peime decomposition


[Package jti version 0.8.4 Index]