|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.ObjectCOM.hugin.HAPI.Node
COM.hugin.HAPI.ContinuousChanceNode
Represents continuous chance nodes with (conditional) Gaussian distributions. Continuous chance nodes are also sometimes called CG nodes (CG for conditional Gaussian).
Constructor Summary | |
ContinuousChanceNode(NetworkModel belongsTo)
Constructs a new continuous chance node. |
Method Summary | |
boolean |
caseIsSet(int c)
Returns true if a value has been set for this
ContinuousChanceNode in case c ; otherwise, returns
false . |
void |
enterValue(double value)
Enters evidence (observation of the value) for this ContinuousChanceNode. |
double |
getAlpha(int i)
Returns the alpha component of the CG distribution of this ContinuousChanceNode given the discrete parent configuration corresponding to i . |
double |
getBeta(ContinuousChanceNode parent,
int i)
Returns the beta component of the CG distribution of this ContinuousChanceNode given a continuous parent and the discrete parent configuration corresponding to i . |
double |
getCaseValue(int c)
Returns the value set for this ContinuousChanceNode in case c . |
NetworkModel.Category |
getCategory()
Returns the Category of this ContinuousChanceNode. |
Table |
getDistribution()
Returns the distribution for this continuous node. |
double |
getEnteredValue()
Returns the evidence (value) entered for this ContinuousChanceNode. |
Table |
getExperienceTable()
Returns the experience table of this ContinuousChanceNode. |
double |
getGamma(int i)
Returns the gamma component of the CG distribution of this ContinuousChanceNode given the discrete parent configuration corresponding to i . |
NetworkModel.Kind |
getKind()
Returns the Kind of this ContinuousChanceNode. |
double |
getMean()
Returns the mean of the marginal distribution of this ContinuousChanceNode. |
double |
getPropagatedValue()
Retrieves the value that has been propagated for this ContinuousChanceNode. |
double |
getSampledValue()
Returns the value of this ContinuousChanceNode for the configuration generated by the most recent call to Domain.simulate() . |
double |
getVariance()
Returns the variance of the marginal distribution of this ContinuousChanceNode. |
boolean |
hasExperienceTable()
Returns true if this ContinuousChanceNode has an
experience table; returns false otherwise. |
void |
retractFindings()
Retracts the evidence (value) entered for this ContinuousChanceNode. |
void |
setAlpha(double alpha,
int i)
Sets the alpha component of the CG distribution of this ContinuousChanceNode given the discrete parent configuration corresponding to i . |
void |
setBeta(double beta,
ContinuousChanceNode parent,
int i)
Sets the beta component of the CG distribution of this ContinuousChanceNode given a continuous parent and the discrete parent configuration corresponding to i . |
void |
setCaseValue(int c,
double value)
Sets the value of this ContinuousChanceNode to value in case c . |
void |
setGamma(double gamma,
int i)
Sets the gamma component of the CG distribution of this ContinuousChanceNode given the discrete parent configuration corresponding to i . |
void |
unsetCase(int c)
Specifies that the value of this ContinuousChanceNode is "unknown" for case c . |
Methods inherited from class COM.hugin.HAPI.Node |
addParent, addToInputs, addToOutputs, clone, delete, evidenceIsEntered, evidenceIsPropagated, evidenceToPropagate, getAttribute, getAttributes, getChildren, getDomain, getEdgeConstraint, getHome, getHomeClass, getHomeDomain, getInstance, getJunctionTree, getLabel, getMaster, getModel, getName, getParents, getPosition, getSource, getTable, getUserData, isAlive, likelihoodIsEntered, likelihoodIsPropagated, removeFromInputs, removeFromOutputs, removeParent, reverseEdge, setAttribute, setAttributes, setEdgeConstraint, setLabel, setName, setPosition, setUserData, switchParent |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public ContinuousChanceNode(NetworkModel belongsTo) throws ExceptionHugin
belongsTo
- the NetworkModel (i.e., Class or Domain)
to which the new node should belong.Method Detail |
public Table getDistribution() throws ExceptionHugin
ExceptionHugin
public double getMean() throws ExceptionHugin
ExceptionHugin
public double getVariance() throws ExceptionHugin
ExceptionHugin
public double getAlpha(int i) throws ExceptionHugin
i
.
i
- the index of a discrete parent configuration.
ExceptionHugin
public double getBeta(ContinuousChanceNode parent, int i) throws ExceptionHugin
i
.
parent
- a ContinuousChanceNode parent of this
ContinuousChanceNode.i
- the index of a discrete parent configuration.
ExceptionHugin
public double getGamma(int i) throws ExceptionHugin
i
.
i
- the index of a discrete parent configuration.
ExceptionHugin
public void setAlpha(double alpha, int i) throws ExceptionHugin
i
.
alpha
- the value of the alpha component.i
- the index of a discrete parent configuration.
ExceptionHugin
public void setBeta(double beta, ContinuousChanceNode parent, int i) throws ExceptionHugin
i
.
beta
- the value of the beta component.parent
- a ContinuousChanceNode parent of this
ContinuousChanceNode.i
- the index of a discrete parent configuration.
ExceptionHugin
public void setGamma(double gamma, int i) throws ExceptionHugin
i
.
gamma
- the value of the gamma component.i
- the index of a discrete parent configuration.
ExceptionHugin
public void enterValue(double value) throws ExceptionHugin
value
- a real number representing the observation.
ExceptionHugin
public double getEnteredValue() throws ExceptionHugin
ExceptionHugin
public Table getExperienceTable() throws ExceptionHugin
ExceptionHugin
public boolean hasExperienceTable() throws ExceptionHugin
true
if this ContinuousChanceNode has an
experience table; returns false
otherwise.
ExceptionHugin
public void retractFindings() throws ExceptionHugin
ExceptionHugin
public double getPropagatedValue() throws ExceptionHugin
ExceptionHugin
public NetworkModel.Category getCategory()
getCategory
in class Node
public NetworkModel.Kind getKind()
getKind
in class Node
public void setCaseValue(int c, double value) throws ExceptionHugin
value
in case c
.
c
- the case index represented as an integer.value
- the value represented as a real number.
ExceptionHugin
public void unsetCase(int c) throws ExceptionHugin
c
.
c
- the case index (an integer in the range 0, ..., number
of cases)
ExceptionHugin
public boolean caseIsSet(int c) throws ExceptionHugin
true
if a value has been set for this
ContinuousChanceNode in case c
; otherwise, returns
false
.
c
- the case index represented as an integer.
ExceptionHugin
public double getCaseValue(int c) throws ExceptionHugin
c
.
ExceptionHugin
public double getSampledValue() throws ExceptionHugin
Domain.simulate()
.
ExceptionHugin
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |