LoopyGibbsSampling.eraseTarget
- LoopyGibbsSampling.eraseTarget(*args)
Remove, if existing, the marginal target.
- Parameters:
target (
int) – a node IdnodeName (
str) – a node name
- Raises:
pyagrum.NotFound – If one of the node does not belong to the Bayesian network
pyagrum.UndefinedElement – If node Id is not in the Bayesian network
- Return type:
None
Example
import pyagrum as gum
bn = gum.fastBN("A->B<-C")
ie = gum.LoopyGibbsSampling(bn)
ie.setTargets({"A", "B"})
ie.eraseTarget("A")
sorted(ie.targets())
# [1]
Class