WhichCells.liger {scCustomize} | R Documentation |
Extract Cells for particular identity
Description
Extract all cell barcodes for a specific identity
Usage
## S3 method for class 'liger'
WhichCells(
object,
idents = NULL,
ident_col = NULL,
by_dataset = FALSE,
invert = FALSE,
...
)
Arguments
object |
LIGER object name. |
idents |
identities to extract cell barcodes. |
ident_col |
name of meta data column to use when subsetting cells by identity values.
Default is NULL, which will use the objects default clustering as the |
by_dataset |
logical, whether to return vector with cell barcodes for all |
invert |
logical, invert the selection of cells (default is FALSE). |
... |
Arguments passed to other methods |
Value
vector or list depending on by_dataset
parameter
Examples
## Not run:
# Extract cells from ident =1 in current default clustering
ident1_cells <- WhichCells(object = liger_object, idents = 1)
# Extract all cells from "stim" treatment from object
stim_cells <- WhichCells(object = liger_object, idents = "stim", ident_col = "Treatment")
## End(Not run)
[Package scCustomize version 3.0.1 Index]