Skip to content
Discussion options

You must be logged in to vote

Hello @fudgerbeige,

To split your object into two separate objects based on assay, you can use the DietSeurat command to keep your assay of interest (make sure to set DefaultAssay beforehand):

#Split to RNA assay
DefaultAssay(obj) <- "RNA"
rna <- DietSeurat(obj, assays = "RNA")

#Split to ATAC assay
DefaultAssay(obj) <- "ATAC"
atac <- DietSeurat(obj, assays = "ATAC")

Alternatively, you can simply subset based on features from each assay, though this would keep any reductions/graphs already in the object:

rna <- subset(obj, features = rownames(obj[["RNA"]]))
atac <- subset(obj, features = rownames(obj[["ATAC"]]))

Hope this helps!

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@fudgerbeige
Comment options

Answer selected by fudgerbeige
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants