Closed kkearns13 closed 1 year ago
Hey Kendall,
scRepertoire has not yet been updated for v5 Seurat. Based on the error, my guess is that the structure of a Seurat Object has changed subtly that breaks the final addition of the contig information to the meta data. I will mark this as a feature request.
In the mean time, a hack to get the data to work would be:
combined.df <- dplyr::bind_rows(combined)
seuratObj <- AddMetaData(combined, combined.df)
The major drawback of this approach would be there is no leveling for "hyperexpanded", "large", etc.
Nick
Hey Kendell,
I tested v5 today with the example data and can't replicate the error - could you provide the data set you are using to help troubleshoot (you can email me a link. If not I will keep trying from my end.
Nick
Hi Nick,
Thank you for working on this over the weekend! I spent some time trying to troubleshoot using the code you shared above and tried some more things but finally I tried using the cell barcodes from the Seurat object as is (ex: AAACCTGAGATCGGGT-1_1
, GACGTGCCAGACGCCT-1_6
). This ended up working!
I realized the way I was renaming the cell barcodes wasn't working with the code. I originally was using gsub
to remove the 1_
from each of the barcodes directly, but using RenameCells
instead or leaving the barcodes as is worked. Not sure why I decided to do it that way, but hopefully this helps someone with a similar issue.
Thanks again for your help!
I've been trying to look for a similar error online but haven't found anything so far... Apologies if I've missed something!
I am trying to use scRepertoire with a Seurat v5 object and have been having issues with the combineExpression function. I am running into this error:
I followed essentially what I did previously (which worked, albeit with an older version of Seurat) with a different dataset - I've reconstructed a TCR repertoire with TRUST4, added the correct suffixes for the barcodes so they match those in the Seurat object, ran
createHTOContigList
on the integrated object (with barcodes fixed). All barcodes ingd_dat
are found inseurat@meta.data
, and all of the Seurat assays have the same number of cells. This is what the Seurat object looks like:Any advice would be much appreciated!