Normal-Block Model with Known Clustering
Source:R/NormalBlockVarKnownClusters.R
NormalBlockVarKnownClusters.RdR6 class for a normal-block model with known clustering.
Super classes
NormalBlockBase -> NormalBlockVarBase -> NormalBlockVarKnownClusters
Active bindings
posterior_para list with the parameters of posterior distribution W | Y
entropyEntropy of the conditional distribution
fittedY values predicted by the model, in Y's original units
who_am_Ia method to print what model is being fitted
Methods
Inherited methods
NormalBlockBase$best_of_inits()NormalBlockBase$candidates_merge()NormalBlockBase$candidates_split()NormalBlockBase$latent_network()NormalBlockBase$optimize()NormalBlockBase$plot()NormalBlockBase$plot_loglik()NormalBlockBase$plot_network()NormalBlockBase$predict()NormalBlockBase$print()NormalBlockBase$update()NormalBlockVarBase$merge()NormalBlockVarBase$split()NormalBlockVarBase$warm_start_from()
NormalBlockVarKnownClusters$new()
Create a new [`NormalBlockVarKnownClusters`] object.
Usage
NormalBlockVarKnownClusters$new(data, C, sparsity = 0, control = NB_control())Examples
ex <- generate_normal_block_var_data(n = 50, p = 20, d = 1, q = 3)
data <- NormalBlockData$new(ex$Y, ex$X)
model <- normal_block(data, blocks = ex$parameters$C, control = NB_control(verbose = FALSE))
model$clustering
#> [1] 2 3 2 1 1 3 2 3 3 3 3 1 3 2 1 1 3 1 3 2