Dune: Dune

Description Usage Arguments Details Value See Also Examples

Description

Compute the ARI between every pair of clustering labels after merging every possible pair of clusters. Find the one that improves the ARI merging the most, merge the pair. Repeat until there is no improvement.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
Dune(clusMat, ...)

## S4 method for signature 'matrix'
Dune(
  clusMat,
  unclustered = NULL,
  verbose = FALSE,
  parallel = FALSE,
  BPPARAM = BiocParallel::bpparam()
)

## S4 method for signature 'data.frame'
Dune(
  clusMat,
  unclustered = NULL,
  verbose = FALSE,
  parallel = FALSE,
  BPPARAM = BiocParallel::bpparam()
)

## S4 method for signature 'SummarizedExperiment'
Dune(
  clusMat,
  cluster_columns,
  unclustered = NULL,
  verbose = FALSE,
  parallel = FALSE,
  BPPARAM = BiocParallel::bpparam()
)

Arguments

clusMat

the matrix of samples by clustering labels.

...

parameters including:

unclustered

The value assigned to unclustered cells. Default to NULL

verbose

Whether or not the print cluster merging as it happens.

parallel

Logical, defaults to FALSE. Set to TRUE if you want to parallellize the fitting.

BPPARAM

object of class bpparamClass that specifies the back-end to be used for computations. See bpparam in BiocParallel package for details. Won't be used if parallel is FALSE.

cluster_columns

if clusMat is a SummarizedExperiment, then this defines the columns of colData that are outputs from a clustering algorithm.

Details

The Dune algorithm merges pairs of clusters in order to improve the mean adjusted Rand Index with other clustering labels. It returns a list with four components.: #'

Value

A list with four components: the initial matrix of clustering labels, the final matrix of clustering labels, the merge info matrix and the ARI improvement vector.

See Also

clusterConversion ARIImp

Examples

1
2
3
4
5
6
7
8
data("clusMat", package = "Dune")
merger <- Dune(clusMat = clusMat)
# clusters 11 to 14 from cluster label 5 and 3 are subset of cluster 2 from
# other cluster labels. Designing cluster 2 as unclustered therefore means we
# do fewer merges.
merger2 <- Dune(clusMat = clusMat, unclustered = 2)
merger$merges
merger2$merges

Dune documentation built on Nov. 8, 2020, 7:55 p.m.