Package edu.cmu.tetrad.bayes
Interface ManipulatingBayesUpdater
- All Superinterfaces:
BayesUpdater
,Serializable
,TetradSerializable
- All Known Implementing Classes:
ApproximateUpdater
,CptInvariantUpdater
,Identifiability
,JunctionTreeUpdater
,RowSummingExactUpdater
Interface for a Bayes updating algorithm that's capable of doing manipulation. In general, manipulating a variable X
will eliminate edges into X, so the updating operation on the manipulated model will produce different results.
- Author:
- josephramsey
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptiondouble
getMarginal
(int variable, int category) void
setEvidence
(Evidence evidence) Sets new evidence for the updater.Methods inherited from interface edu.cmu.tetrad.bayes.BayesUpdater
calculatePriorMarginals, calculateUpdatedMarginals, getBayesIm, getJointMarginal, isJointMarginalSupported
-
Field Details
-
serialVersionUID
static final long serialVersionUID- See Also:
-
-
Method Details
-
getManipulatedBayesIm
BayesIm getManipulatedBayesIm()- Returns:
- the Bayes instantiated model after manipulations have been applied.
-
getManipulatedGraph
Graph getManipulatedGraph()- Returns:
- the graph for the manipulated BayesIm.
-
getEvidence
Evidence getEvidence()- Returns:
- a defensive copy of the evidence.
-
setEvidence
Sets new evidence for the updater. Once this is called, old updating results should not longer be available.- Specified by:
setEvidence
in interfaceBayesUpdater
-
getUpdatedBayesIm
BayesIm getUpdatedBayesIm()- Returns:
- the updated Bayes IM--that is, the Bayes IM in which all probabilities of variables conditional on their parents have been updated.
-
getMarginal
double getMarginal(int variable, int category) - Specified by:
getMarginal
in interfaceBayesUpdater
- Returns:
- P(variable = category | evidence) where evidence is getEvidence().
-