gatingMatrix {flowSpy} | R Documentation

## Apply gating on the matrix data

### Description

Apply gating on the matrix data

### Usage

    gatingMatrix(x, lower.gate = NULL, upper.gate = NULL)

### Arguments

`x` | matrix
`lower.gate` | vector. Gating parameter, the name of the vector is the marker name, and the value of the vector is the lower bound of gating cutoff.
`upper.gate` | vector. Gating parameter, the name of the vector is the marker name, and the value of the vector is the upper bound of gating cutoff.

### Value

a matrix

### Examples

    par(mfrow=c(1,2))
    x <- matrix(rnorm(200, 3, 1), nrow = 100, ncol = 2)
    colnames(x) <- c("CD34", "CD43")
    plot(x[, "CD34"], x[, "CD43"], main = "Before gating")

    lower.gate = c(CD34 = 2, CD43 = 3)
    upper.gate = c(CD34 = 4, CD43 = 5)

    x <- gatingMatrix(x, lower.gate = lower.gate, upper.gate = upper.gate)
    plot(x[, "CD34"], x[, "CD43"], main = "After gating")

    par(mfrow=c(1,1))

[Package flowSpy version 1.0.4 Index]