ncborcherding / scRepertoire

A toolkit for single-cell immune profiling
https://www.borch.dev/uploads/screpertoire/
MIT License
311 stars 54 forks source link

How to map barcode of scTCRseq and scRNAseq #391

Closed synatkeamsk closed 4 months ago

synatkeamsk commented 4 months ago

Dear Nick and your team,

Thank you very much for your great package. I am approaching to wrap up my scTCRseq analysis, but I would like to ask one more question.

I first started by analyzing just scTCRseq and found one clone has the largest expansion compared with other clone using clonalScatter . Kindly review Figure-1 with clone I circle in red.

Figure 1

Next I integrated scTCRseq with scRNAseq and I found CD8 were highly expanded compared with other cluster (red circle in Figure 2). So I suspected the high expanded clone I saw in Figure-1 could be CD8. Do you know how to verify this? This is important for our publication, but Im not sure how to do it. Do you have a simple and quick way to verify it or map barcode to check. Hope you could help.

Figure 2

Kind Regards,

Synat,

ncborcherding commented 4 months ago

Hey Synat,

You can get all the info for the clonalScatter() plot using exportTable = TRUE. Then you can check where the clone is on your UMAP?

Nick

synatkeamsk commented 4 months ago

Thanks you Nick for your continued support. I will try to do export table.

I have another issue with consistency of top 10 clone in clonalCompare. with clonalCompare, I wanted to get top 10, but in some cases I could not call it to get exactly 10. For example, with the following code. I had to reduce it to 8, top.clones= 8 to get 11 clone and if I added top.clones= 7, I got only 9. So I could not get top 10 in this case. I tried to add decimal, but got error!

clonalCompare(combined, 
                  top.clones = 8, 
                  samples = c("first", "second"), 
                  cloneCall="aa", 
              relabel.clones = TRUE,
                  graph = "alluvial", 
              palette = "Dark 3") + 
theme_classic() + 
  theme(plot.title = element_text(size = 15, face = "bold", hjust = 0.5),
     axis.text.x = element_text(angle=90,hjust=0.95,vjust=0.2, face = "bold", size = 18), 
         axis.text.y = element_text(face = "bold", size = 18), 
         axis.title.y = element_text(face = "bold", size = 20), 
          axis.title.x = element_blank(),
         legend.title = element_text(size = 18, face = "bold"), 
         legend.text = element_text(size = 14, face = "bold"))

fig1

Kind Regards,

synat,

ncborcherding commented 4 months ago

Hey Synat,

This is because there are ties in the total proportion of several clones. I think what your numbers are showing is there might be multiple ties.

Nick