View source: R/voteLabelTransfer.R
voteLabelTransfer | R Documentation |
A wrapper for doing either labelTransfer or labelTransferEllipse.
voteLabelTransfer(
type = "points",
test.partition,
test.cytometry,
test.partition.ellipse,
training.cytometries,
training.cytometries.barycenter,
test = 1,
op.syst,
cl.paral = 1,
equal.weights = FALSE
)
type |
'points' indicates use of labelTransfer; 'ellipses' of labelTransferEllipse. |
test.partition |
Only when type = 'points'. Labels of a partition of the test data. |
test.cytometry |
Only when type = 'points'. Test data, a dataframe without labels. |
test.partition.ellipse |
Only when type = 'ellipses'. A test clustering viewed as a mixture of multivariate normal distributions. |
training.cytometries |
Only when type = 'points'. List of partitions, where each partition is a dataframe wher the last column contains the labels of the partition. |
training.cytometries.barycenter |
Only when type = 'ellipses'. A training partition viewed as a mixture of multivariate normal distributions. |
test |
Only when type = 'ellipses'. A dummy variable, should be any integral. Ment for use with lapply. |
op.syst |
Type of system, takes values in c('unix', 'windows'). |
cl.paral |
Number of cores to be used in parallel procedures. |
equal.weights |
If True, weights assigned to every cluster in a partion are uniform (1/number of clusters) when calculating the similarity distance. If False, weights assigned to clusters are the proportions of points in every cluster compared to the total amount of points in the partition. |
A list containing:
A list for the votes on each cell.
A more complete list for the votes on each cell.
data.example <- data.frame(v1 = c(rnorm(50, 2, 1), rnorm(50, -2, 1)),
v2 = c(rnorm(50, 2, 1), rnorm(50, -2, 1)), id = c(rep(0, 50), rep(1, 50)))
test.labels <- c(rep('a', 50), rep('b', 50))
voteLabelTransfer(test.partition = test.labels, test.cytometry = data.example[, 1:2],
training.cytometries = list(data.example), op.syst = .Platform$OS.type)$final.vote[[1]]
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.