Filtering single-cell count matrix based on scrublet output
Hi,
I have output files from cell ranger (matrix, barcodes, features) as well as scrublet output files for the count matrix. I want to filter the count matrix based on the scrublet data. Is it wise to convert mtx to csv, manipulate data and convert it back to mtx? Or what is the best way to do this?
Thank you very much!
• 1,794 views
•
link
1 answer
Are you using scanpy?
If you are, you can use the wrapper scanpy.pp.external.scrublet function.
This function uses the scrublet package. The function adds a new column into the AnnData observation (e.g. adata.obs) dataframe called predicted_doublet. You can subset your AnnData frame using that column, e.g.
adata[adata.obs.['predicted_doublet`]]
• 0 views
•
link
Log in to answer this question.