pyhgf.updates.prediction.binary.binary_state_node_prediction#

pyhgf.updates.prediction.binary.binary_state_node_prediction(attributes: Dict, edges: Tuple[AdjacencyLists, ...], node_idx: int, **args) Dict[source]#

Get the new expected mean and precision of a binary state node.

The predictions of a binary state node \(b\) at time \(k\) depends on the prediction of its value parent \(a\), such as:

\[\hat{\mu}_b^{(k)} = \frac{1}{1 + e^{-\hat{\mu}_a^{(k)}}}\]

and

\[\hat{\pi}_b^{(k)} = \frac{1}{\hat{\mu}^{(k)}(1-\hat{\mu}^{(k)})}\]
Parameters:
attributes

The attributes of the probabilistic nodes.

edges

The edges of the probabilistic nodes as a tuple of pyhgf.typing.Indexes. The tuple has the same length as the node number. For each node, the index lists the value and volatility parents and children.

time_step

The interval between the previous time point and the current time point.

node_idx

Pointer to the binary state node.

Returns:
attributes

The attributes of the probabilistic nodes.