bn2pta: computes the probability table associated to a numcat/parcat...

Description Usage Arguments Details Value Examples

Description

(bn) In case of a numcat node, provides its conditional probability table as defined in the bn. The number of dimensions of the array is one plus the number of the node parents. The order of the node parents is not modified and the position number of the child node is given by pos.

Usage

1
bn2pta(bn, ion, pos=2)

Arguments

bn

the bn.

ion

identification of the node. This node must be a numcat node.

pos

index position for the child node. When there are no parents, this argument is forced to one.

Details

Remenber that the order in @npara\$p corresponds to pos with the greatest value.

Value

the resulting pta object

Examples

1
2
3
4
5
6
7
 rebastaba3k("RESET"); # (only for R checking)
 uu <- and4bn(rebastaba.bn1, new8alk(char2des("NC1"), ltype="numcat", 
 lpara=list(p=1:4), lpod=list(LETTERS[1:4])))
 uu <- and4bn(uu, new8alk(char2des("NC2"), ltype="numcat", lparent="NC1", 
 lpara=list(p=matrix(1:12, 4)), lpod=list(letters[1:3])))
 print(bn2pta(uu, "NC1"));
 print(bn2pta(uu, "NC2"));

rebastaba documentation built on May 2, 2019, 5:24 p.m.

Related to bn2pta in rebastaba...