Learn R Programming

rtkpp (version 0.8.5)

clusterInit: Create an instance of [ClusterInit] class

Description

The initialization step is a two stages process: the proper initialization step and some (optionnals) iterations of an algorithm [clusterAlgo].

Usage

clusterInit(method = "class", nbInit = 5, algo = "SEM",
  nbIteration = 20, epsilon = 0.01)

Arguments

method
Character string with the initialisation method. Possible values: "random", "class", "fuzzy". Default value is "class".
nbInit
integer defining the number of initialization point to test. Default value is 5.
algo
Character string with the initialisation algorithm. Possible values: "EM", "CEM", "SEM", "SemiSEM". Default value is "SEM".
nbIteration
Integer defining the number of iteration in algo. nbIteration must be a positive integer. Default values is 20. Not used if algo = NULL.
epsilon
Real defining the epsilon value for the algorithm. Default value: 0.01.

Value

  • a [ClusterInit] object

Details

There is three ways to initialize the parameters:
  • random{The initial parameters of the mixture are chosen randomly.}
  • class{The initial membership of individuals are sampled randomly.}
  • fuzzy{The initial probabilities of membership of individuals are sampled randomly.}
A few iteration of an algorithm [clusterAlgo] are then performed. It is strongly recommended to use a few number of iterations of the SEM or CEM algorithms after initialization. This allow to detect "bad" initialization starting point of the estimation algorithm.

These two stages are repeated until nbInit is reached. The initial point with the best log-likelihood is conserved as the initial starting point.

Examples

Run this code
clusterInit(method = "class", nbInit=1, algo="CEM",nbIteration=50, epsilon=0.00001)
 clusterInit(nbIteration=0) # no algorithm

Run the code above in your browser using DataLab