
Get the index position for a gene
get_gene_indices.RdReturns the index for a given gene based on the internal gene mapping. This is used for the single cell-related classes and methods.
Usage
get_gene_indices(x, gene_ids, rust_index)
## S7 method for class <bixverse::MetaCells>
get_gene_indices(x, gene_ids, rust_index)
# S3 method for class 'ScMap'
get_gene_indices(x, gene_ids, rust_index)
## S7 method for class <bixverse::SingleCells>
get_gene_indices(x, gene_ids, rust_index)
## S7 method for class <bixverse::SingleCellsSubset>
get_gene_indices(x, gene_ids, rust_index)Examples
# R-based positions of two genes
sc <- demo_single_cells(prepped = FALSE)
get_gene_indices(sc, c("gene_01", "gene_02"), rust_index = FALSE)
#> [1] 1 2
unlink(sc@dir_data, recursive = TRUE, force = TRUE)