Learn R Programming

rhierbaps (version 1.1.4)

reallocate_units_4: reallocate_units_4

Description

Peform an iteration of the fourth move in the algorithm. That is split cluster into n subclusters and re-allocate one sub-cluster.

Usage

reallocate_units_4(
  snp.object,
  partition,
  threshold = 1e-05,
  min.clust.size = 20,
  split = FALSE,
  n.cores = 1
)

Value

The best partition after splitting a cluster and re-allocating as well as a boolean value indicating whether a move increased the marginal likelihood.

Arguments

snp.object

A snp.object containing the processed SNP data.

partition

An integer vector indicating an initial partition of the isolates.

threshold

The increase in marginal log likelihood required to accept a move.

min.clust.size

Clusters smaller than min.clust.size will not be split.

split

Whether to split only into two clusters (for move type 3).

n.cores

The number of cores to use.