train_gp_clust {MagmaClustR} | R Documentation |
Prediction in MagmaClust: learning new HPs and mixture probabilities
Description
Learning hyper-parameters and mixture probabilities of any new
individual/task is required in MagmaClust
in the prediction procedure.
By providing data for the new individual/task, the hyper-posterior mean and
covariance parameters, the mixture proportions, and initialisation values for
the hyper-parameters, train_gp_clust
uses an EM algorithm to compute
maximum likelihood estimates of the hyper-parameters and hyper-posterior
mixture probabilities of the new individual/task.
Usage
train_gp_clust(
data,
prop_mixture = NULL,
ini_hp = NULL,
kern = "SE",
hyperpost = NULL,
pen_diag = 1e-10,
n_iter_max = 25,
cv_threshold = 0.001
)
Arguments
data |
A tibble or data frame. Required columns: |
prop_mixture |
A tibble or a named vector. Each name of column or element should refer to a cluster. The value associated with each cluster is a number between 0 and 1, corresponding to the mixture proportions. |
ini_hp |
A tibble or data frame of hyper-parameters
associated with |
kern |
A kernel function, defining the covariance structure of the GP. Several popular kernels (see The Kernel Cookbook) are already implemented and can be selected within the following list:
|
hyperpost |
A list, containing the elements |
pen_diag |
A number. A jitter term, added on the diagonal to prevent numerical issues when inverting nearly singular matrices. |
n_iter_max |
A number, indicating the maximum number of iterations of the EM algorithm to proceed while not reaching convergence. |
cv_threshold |
A number, indicating the threshold of the likelihood gain under which the EM algorithm will stop. |
Value
A list, containing the results of the EM algorithm used during the prediction step of MagmaClust. The elements of the list are:
hp: A tibble of optimal hyper-parameters for the new individual's GP.
mixture: A tibble of mixture probabilities for the new individual.
Examples
TRUE