View source: R/miscFunctions.R
setRowNames | R Documentation |
Users can set rownames of an SCE object with either a character
vector where the length equals to nrow(x)
, or a single character
specifying a column in rowData(x)
. Also applicable to matrix like
object where rownames<-
method works, but only allows full size name
vector. Users can set dedup = TRUE
to remove duplicated entries in the
specification, by adding -1, -2, ..., -i
suffix to the duplication of
the same identifier.
setRowNames(x, rowNames, dedup = TRUE)
x |
Input object where the rownames will be modified. |
rowNames |
Character vector of the rownames. If |
dedup |
Logical. Whether to deduplicate the specified rowNames. Default
|
The input SCE object with rownames updated.
data("scExample", package = "singleCellTK")
head(rownames(sce))
sce <- setRowNames(sce, "feature_name")
head(rownames(sce))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.