Read a 10x Genomics Gene Expression Sample into a Seurat Object
read_10x_GEX.RdReads a single sample's filtered feature barcode matrix H5 file from a 10x
Genomics Cell Ranger output directory and creates a
Seurat object. A log10 genes-per-UMI
complexity metric is added to the object metadata as log10GenesPerUMI.
Arguments
- sampleDir
Character string. Path to the parent directory that contains one subdirectory per sample.
- sample
Character string. Name of the sample subdirectory within
sampleDir.- ident
Character string. Identity label to assign to every cell in the resulting Seurat object (stored in the
identmetadata column).- min.cells
Integer. Include features detected in at least this many cells. Passed to
Seurat::CreateSeuratObject().- min.features
Integer. Include cells where at least this many features are detected. Passed to
Seurat::CreateSeuratObject().
Value
A Seurat object for the specified
sample with the RNA assay, an ident metadata column, and a
log10GenesPerUMI complexity metric.
Details
The expected input path is
<sampleDir>/<sample>/outs/filtered_feature_bc_matrix.h5. To process
multiple samples, iterate over sample names with purrr::map() or
lapply().