Description Usage Arguments Value Author(s) See Also Examples
View source: R/celda_functions.R
This will return indices of features among the rownames
or rowData of a data.frame, matrix, or a SummarizedExperiment
object including a SingleCellExperiment.
Partial matching (i.e. grepping) can be used by setting
exactMatch = FALSE
.
1 2 3 4 5 6 7 | retrieveFeatureIndex(
features,
x,
by = "rownames",
exactMatch = TRUE,
removeNA = FALSE
)
|
features |
Character vector of feature names to find in the rows of
|
x |
A data.frame, matrix, or SingleCellExperiment object to search. |
by |
Character. Where to search for features in |
exactMatch |
Boolean. Whether to only identify exact matches
or to identify partial matches using |
removeNA |
Boolean. If set to |
A vector of row indices for the matching features in x
.
Yusuke Koga, Joshua Campbell
'retrieveFeatureInfo' from package 'scater'
and link{regex}
for how to use regular expressions when
exactMatch = FALSE
.
1 2 3 4 | data(celdaCGSim)
retrieveFeatureIndex(c("Gene_1", "Gene_5"), celdaCGSim$counts)
retrieveFeatureIndex(c("Gene_1", "Gene_5"), celdaCGSim$counts,
exactMatch = FALSE)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.