Description Usage Arguments Value Author(s) Examples
blr_cluster
is a wrapper function that clusters methylation
profiles using the EM algorithm. Initially, it performs parameter checking,
and initializes main parameters, such as mixing proportions, basis function
coefficients, then the EM algorithm is applied and finally model selection
metrics are calculated, such as BIC and AIC.
1 2 3 |
x |
The Gaussian distributed observations, which has to be a list of elements of length N, where each element is an L x 2 matrix of observations, where 1st column contains the locations and the 2nd column contains the methylation levels. |
K |
Integer denoting the number of clusters K. |
pi_k |
Vector of length K, denoting the mixing proportions. |
w |
A MxK matrix, where each column consists of the basis function coefficients for each corresponding cluster. |
basis |
A 'basis' object. E.g. see |
s2 |
Vector of initial linear regression variances for each cluster. |
em_max_iter |
Integer denoting the maximum number of EM iterations. |
epsilon_conv |
Numeric denoting the convergence parameter for EM. |
lambda |
The complexity penalty coefficient for ridge regression. |
is_verbose |
Logical, print results during EM iterations. |
A 'blr_cluster' object which, in addition to the input parameters, consists of the following variables:
pi_k
: Fitted mixing proportions.
w
: A MxK matrix
with the fitted coefficients of the basis functions for each cluster k.
NLL
: The Negative Log Likelihood after the EM algorithm has
finished.
post_prob
: Posterior probabilities of each promoter
region belonging to each cluster.
labels
: Hard clustering
assignments of each observation/promoter region.
BIC
:
Bayesian Information Criterion metric.
AIC
: Akaike
Information Criterion metric.
ICL
: Integrated Complete
Likelihood criterion metric.
C.A.Kapourani C.A.Kapourani@ed.ac.uk
1 | my_clust <- blr_cluster(x = lm_data, em_max_iter = 100, is_verbose = TRUE)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.