specMatCalc: Calculating the matrix used for spectral unmixing

Description Usage Arguments Value Examples

View source: R/specMatCalc.R

Description

This algoritm takes a flowSet containing single-stained controls and negative controls, including an autofluorescence control and estimates the unmixing for all fluorescent variables.

Usage

1
specMatCalc(compControls, groupNames, autoFluoName)

Arguments

compControls

A flowSet containing all the single stained and unstained files necessary to create an spectral unmixing matrix.

groupNames

A character vector containing strings common to the groups of non-autofluoresence compControls that could be present. If for example all antibodies single stains are anti-mouse bead-based the dead cell marker is stained PBMC, and the files congruently either have a prefix containing "Bead" or "PBMC", then the vector should be c("Bead", "PBMC"). The system is not case specific.

autoFluoName

The sample name of the autofluorescence control.

Value

A data frame with each row representing a fluorochrome or or autofluorescence and each column representing a detector.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
# Load suitable compensation controls. NB! If these originate from different
#sample types, such as beads and PBMC, there should be a negative control for
#each group and the names should reflect this, so that all PBMC samples would
#be called PBMC_unstained, PBMC_DCM, etc.
data(compCtrls)

#If  the dataset contains cell controls, make sure that the cell population
#interest dominates FSC-A, as the data highest peak in this channel will be
#used.

# And run the function
specMat <- specMatCalc(compCtrls, groupNames = "Beads_", autoFluoName =
"PBMC_autofluo.fcs")

jtheorell/theFlowSpec documentation built on Aug. 22, 2019, 3:33 a.m.