SetMotifData | R Documentation |
Set motif matrix for given assay
SetMotifData(object, ...)
## S3 method for class 'Motif'
SetMotifData(object, slot, new.data, ...)
## S3 method for class 'ChromatinAssay'
SetMotifData(object, slot, new.data, ...)
## S3 method for class 'Seurat'
SetMotifData(object, assay = NULL, ...)
object |
A Seurat object |
... |
Arguments passed to other methods |
slot |
Name of slot to use |
new.data |
motif matrix to add. Should be matrix or sparse matrix class |
assay |
Name of assay whose data should be set |
Returns a Seurat
object
motif.obj <- SeuratObject::GetAssayData(
object = atac_small[['peaks']], slot = "motifs"
)
SetMotifData(object = motif.obj, slot = 'data', new.data = matrix(1:2))
SetMotifData(
object = atac_small[['peaks']], slot = 'data', new.data = matrix(1:2)
)
motif.matrix <- GetMotifData(object = atac_small)
SetMotifData(
object = atac_small, assay = 'peaks', slot = 'data', new.data = motif.matrix
)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.