Class DistributionSpecification
- java.lang.Object
-
- com.bayesserver.learning.parameters.DistributionSpecification
-
public final class DistributionSpecification extends Object
Identifies a node's distribution to learn, and options for learning. Note that temporal nodes and noisy nodes can have multiple distributions, and each distribution is identified by temporal order.
-
-
Constructor Summary
Constructors Constructor Description DistributionSpecification(Node node)
Initializes a new instance of theDistributionSpecification
class.DistributionSpecification(Node node, int order)
Initializes a new instance of theDistributionSpecification
class.DistributionSpecification(Node node, NodeDistributionKey key)
Initializes a new instance of theDistributionSpecification
class.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description DiscretePriorMethod
getDiscretePriorMethod()
Gets the type of discrete prior to use for this distribution.Boolean
getInitialize()
Gets a flag indicating whether the distribution should be initialized.NodeDistributionKey
getKey()
Gets the order/related node of the distribution.Node
getNode()
Gets theNode
this distribution specification refers to.int
getOrder()
Gets the order of the distribution, for temporal nodes.Node
getRelatedNode()
Gets the related node (if any) of the distribution.void
setDiscretePriorMethod(DiscretePriorMethod value)
Sets the type of discrete prior to use for this distribution.void
setInitialize(Boolean value)
Sets a flag indicating whether the distribution should be initialized.
-
-
-
Constructor Detail
-
DistributionSpecification
public DistributionSpecification(Node node)
Initializes a new instance of theDistributionSpecification
class.- Parameters:
node
- The node the distribution refers to.
-
DistributionSpecification
public DistributionSpecification(Node node, int order)
Initializes a new instance of theDistributionSpecification
class.- Parameters:
node
- The node the distribution refers to.order
- The order of the distribution, for temporal nodes.
-
DistributionSpecification
public DistributionSpecification(Node node, NodeDistributionKey key)
Initializes a new instance of theDistributionSpecification
class.- Parameters:
node
- The node the distribution refers to.key
- Properties that identify the distribution, such as the temporal order.
-
-
Method Detail
-
getInitialize
public Boolean getInitialize()
Gets a flag indicating whether the distribution should be initialized. Whennull
InitializationOptions.getInitializeDistributions()
will be used to determine whether initialization is performed.- Returns:
- When
true
initialize the distribution, whenfalse
do not initialize the distributions, and whennull
use the value fromInitializationOptions.getInitializeDistributions()
.
-
setInitialize
public void setInitialize(Boolean value)
Sets a flag indicating whether the distribution should be initialized. Whennull
InitializationOptions.getInitializeDistributions()
will be used to determine whether initialization is performed.- Parameters:
value
- Whentrue
initialize the distribution, whenfalse
do not initialize the distributions, and whennull
use the value fromInitializationOptions.getInitializeDistributions()
.
-
getDiscretePriorMethod
public DiscretePriorMethod getDiscretePriorMethod()
Gets the type of discrete prior to use for this distribution. Whennull
com.bayesserver.learning.parameters.PriorOptions#getDiscretePriorMethod
will be used to determine the type of prior.
-
setDiscretePriorMethod
public void setDiscretePriorMethod(DiscretePriorMethod value)
Sets the type of discrete prior to use for this distribution. Whennull
com.bayesserver.learning.parameters.PriorOptions#getDiscretePriorMethod
will be used to determine the type of prior.
-
getOrder
public int getOrder()
Gets the order of the distribution, for temporal nodes. For non temporal nodes this value will always be zero.
-
getRelatedNode
public Node getRelatedNode()
Gets the related node (if any) of the distribution. e.g. for noisy nodes.
-
getKey
public NodeDistributionKey getKey()
Gets the order/related node of the distribution. For non temporal nodes this value will always be zero.
-
-