| dimnames.Assay | R Documentation |
Get and set feature and cell names in v5 Assays
## S3 method for class 'Assay'
dimnames(x)
## S3 replacement method for class 'Assay'
dimnames(x) <- value
x |
An |
value |
A two-length list where the first entry is the existing feature
names for |
dimnames: A two-length list with the following values:
A character vector will all features in x
A character vector will all cells in x
dimnames<-: x with the cell names updated to those
in value[[2L]]
v3 Assay object, validity, and interaction methods:
$.Assay(),
Assay-class,
Assay-validity,
CreateAssayObject(),
[.Assay(),
[[.Assay(),
dim.Assay(),
merge.Assay(),
split.Assay(),
subset.Assay()
Cells(),
dimnames.Assay5(),
dimnames.Seurat()
rna <- pbmc_small[["RNA"]]
# Feature and cell names can be acquired with `rownames` and `colnames`
head(rownames(rna))
head(colnames(rna))
# Cell names can be updated with `colnames<-`
colnames(rna)[1] <- "newcell"
head(colnames(rna))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.