This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Create a new seurat object using one cluster identified in a previous seurat object

Hello, I would like to create a separated seurat object using only 1 cluster previous identified in the same seurat object to explore different subtypes on NK cell phenotypes inside this cluster. I am not fcompletely familiar with R and I anot sure what code should I use. Can anyone help me? Thank you

object seurat create clusterization

1 answer

You can subset your data based on any meta.data column. For example, if your clusters are stored in my_clusters column, run:

new_seurat_object <- original_seurat_object %>% subset(my_clusters == 'cluster_name')

Similarly, you can subset your data based on cell identity:

new_seurat_object <- original_seurat_object %>% subset(idents = 'cluster_name')

Log in to answer this question.