How to use WhichCells Function to label clusters
0
0
Entering edit mode
5.3 years ago
world • 0

The WhichCells function can pull the names of cells that were experimentally marked as iPS cells, and find that they have been placed in cluster 7)

ips.cells=WhichCells(nbt,"iPS",id = "orig.ident")

my.data=FetchData(nbt,"ident",cells.use = ips.cells)

head(my.data,2)

              ident

 Hi_iPS_1     7

 Hi_iPS_2     7
  

When I use the function though, the idents column do not return the cluster ID

FetchData(stemcells, c("ident", "orig.ident"))

                 ident orig.ident
old_LT_HSC_2       old        old
old_LT_HSC_3       old        old
  

Before, I've subsetted my data into control and stimulated cells. How can I get the cluster ID for all the cells?

R Seurat • 3.2k views
ADD COMMENT
0
Entering edit mode

Your question/post is a little bit raw but from what I understand you are using Seurat for single cell analysis. As far as I can see from your code, you are feeding different objects nbd and stemcells to WhichCells() and FetchData() respectively, I am not surprised that you get different outputs.

And for your question on how to get cluster ID, please check the @meta.data slot of your Seurat object. If I remember correctly cluster ids are stored in a column for which the column name is either prefixed our suffiexed by "res" and then the "resolution" parameter used for clustering.

ADD REPLY

Login before adding your answer.

Traffic: 1590 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6