find_prefix_in_cell_IDs: Check Prefix in Seurat Object Cell IDs

View source: R/Seurat.Utils.R

find_prefix_in_cell_IDsR Documentation

Check Prefix in Seurat Object Cell IDs

Description

This function checks if a prefix has been added to the standard cell-IDs (16 characters of A,TRUE,C,G) in a Seurat object. If so, it prints the number of unique prefixes found, issues a warning if more than one unique prefix is found, and returns the identified prefix(es).

Usage

find_prefix_in_cell_IDs(obj, cell_ID_pattern = "[ATCG]{16}.*$")

Arguments

obj

A Seurat object with cell IDs possibly prefixed.

cell_ID_pattern

Pattern to match cellIDs (with any suffix).

Value

A character vector of the identified prefix(es).

Examples

# Assuming 'obj' is your Seurat object
# prefix <- find_prefix_in_cell_IDs(obj)


vertesy/Seurat.utils documentation built on Dec. 4, 2024, 5:20 p.m.