update_alpha: update_alpha

View source: R/update_alpha.R

update_alphaR Documentation

update_alpha

Description

Internal function to update alpha - the adjacency matrix that represents connections between input variables and hidden variables.

Usage

update_alpha(data, p_y_given_x_3d, tcs, tc_min, log_p_y, log_marg_x_4d)

Arguments

data

Data provided by user.

p_y_given_x_3d

A 3D array of numerics in range (0, 1), that represent the probability of n_hidden latent variables of dimension dim_hidden, for each observed x variable with dimensions (n_hidden, n_samples, dim_hidden).

tcs

Vector of length n_hidden - contains the TC for each hidden factor. This is used to decided the sort order for all the other parameters such that hidden factors are returned to used in order of largest TC to smallest TC.

tc_min

Minimum value which is allowed for TC for any given hidden variable.

log_p_y

A 2D matrix representing the log of the marginal probability of the latent variables.

log_marg_x_4d

A 4D array that contains the value of the marginal distribution for each variable, for each dimension of each hidden variable and for each data row.

Value

Returns an updated alpha matrix - an adjacency matrix between input variables and hidden variables.


jpkrooney/rcorex documentation built on July 25, 2022, 1:37 a.m.