check-scalar-matchesUniqueGeneNames | R Documentation |
This assert check determines if a user-defined gene name query is using only unique (non-amgibuous) symbols. It is designed to be used for gene plotting particularly when performing single-cell RNA-seq marker analysis.
matchesUniqueGeneNames(x, genes)
x |
Object. |
genes |
|
TRUE
on success;
FALSE
on failure, with cause set.
Updated 2022-10-18.
x <- SummarizedExperiment::SummarizedExperiment(
assays = matrix(
data = seq_len(16L),
nrow = 4L,
ncol = 4L,
dimnames = list(
paste0("gene", seq_len(4L)),
paste0("sample", seq_len(4L))
)
),
rowData = S4Vectors::DataFrame(
"geneId" = paste0("ENSG0000000000", seq_len(4L)),
"geneName" = paste0("SYMBOL", seq_len(4L))
)
)
genes <- SummarizedExperiment::rowData(x)$geneName
## TRUE ====
matchesUniqueGeneNames(x = x, genes = genes)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.