Description Usage Arguments Details Value Examples
View source: R/fit.fmmstil.parallel.R
This function finds the penalised quasi likelihood estiamtes for finite mixture of mstil via EM in parallel.
1 2 3 4 5 6 7 8 9 10 | fit.fmmstil.parallel(
x,
K,
ncore = 1,
param = NULL,
init.cluster,
init.param.method,
show.progress = TRUE,
control = list()
)
|
x |
matrix of quantiles of size n x k. Each row is taken as a quantile. |
K |
number of clusters. |
ncore |
number of core to be used. |
param |
list of lists of inital parameters, containing omega, lambda, delta, Ainv, and nu. |
init.cluster |
(optional) initial clusters used to find initial parameters. |
init.param.method |
(optional) method to obtain initial parameters. It needs to be a function of x and K, and return a list of list of parameters. |
show.progress |
a logical value. If TRUE, progress of the algorithm will be printed in console. By default TRUE. |
control |
list of control variables, see 'details'. |
The control argument is a list that accepts the following components.
a positive integer, represents the number of samples used to estimate the density and log-likelihood functions. By default 1e6.
a value between 0.5 and 1, represents the confidence level of the log-likelihood to be calculated. By default 0.95.
a positive integer. The algorithm stops when the estimated log-likelihood is not improved in cvgN iterations. By default 5.
a positive value, represents the L2 penalty coefficient for lambda. By default 1e-6.
a positive value, represents the L2 penalty coefficient for Ainv. By default 1e-6.
a positive integer, represents the maximum number of EM iterations allowed. By default 1e3.
a positive integer, represents the maximum number of iterations in optim allowed within each M-step. By default 10.
a positive integer, represents the number of samples used to estimate the gradient. By default 1e4.
a positive value, represents the step size to estimate gradient w.r.t. nu. By default 1e-5.
a positive value, represents the step size to be used in the stochastic gradient step to optimise nu. By default 1e-2.
a positive integer, represents the number of iterations to be used in the stochastic gradient step to optimise nu. By default 1e2.
a positive value, represents the diminishing rate for step size to be used in the stochastic gradient step to optimise nu. By default 1e-2.
a positive integer, represents the batch sample size. By default n.
a list with components:
logLik |
a vector of the estimated log-likelihood after each itereation. |
par |
a list of lists of lists of fitted parameters after each iteration. |
time |
a vector recorded the time elapsed after each iteration. |
1 2 3 | # Not run:
# data(RiverFlow)
# fit.fmmstil(as.matrix(log(RiverFlow)), 2)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.