MonteCarloSampling.eraseTarget
- MonteCarloSampling.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.MonteCarloSampling(bn)
ie.eraseTarget("A")
sorted(ie.targets())
# [1, 2]
Class
Overridden in