searchCluster: Search for clusters using pre-defined labels

Description Usage Arguments Value Examples

View source: R/searchCluster.R

Description

A function that searches for clusters using pre-defined labels (cell definitions).

Usage

1
2
searchCluster(fcsFrame, clusterLabel, cutoff = NULL, rmNull = TRUE,
  preGate = NULL)

Arguments

fcsFrame

A flowFrame object.

clusterLabel

A vector of labels, such as "CD3+|CD4+|CD8-". Each marker is followed by "+" or "-" and are separated by "|".

cutoff

A vector of cutoff values to bisect the distribution of each marker. The names of the vector should be the same as the marker names. If NULL, the cutoff value will be determined automatically.

rmNull

True or False. Used to specify if a cluster with 0 cells should be returned or not.

preGate

A character string specifying the gated used to clean up the data. For example, use "PI-" to only analyze live cell. Or use "Cell_Length+" to only analyze non-debris.

Value

Returns a list with two components: 1) clusterList is a list in which each element of the list is a vector containing the ID of all cells in a cluster. The names correspond to the labels specified in clusterLabel. 2) cutoff, contains a vector of cutoff values used to bisect each marker.

Examples

1
2
3
4
5
6
7
8
9
# Find fcs files
files=system.file("extdata","SDY420/ResultFiles/CyTOF_result",
                  package="MetaCyto")
files=list.files(files,pattern="fcs$",full.names=TRUE)
# Preprocess
fcs = preprocessing(fcsFiles=files,assay ="CyTOF",b=1/8)
# Search clusters
cluster_list=searchCluster(fcsFrame=fcs,
                           clusterLabel=c("CD3+|CD8+","CD3-|CD19+"))

MetaCyto documentation built on Nov. 8, 2020, 7:50 p.m.