constantAmateur / SoupX

R package to quantify and remove cell free mRNAs from droplet based scRNA-seq data
249 stars 34 forks source link

Error in quickMarkers #92

Closed vertesy closed 2 years ago

vertesy commented 2 years ago

Hi Matthew,

I encounter this error when running quickMarkers:

mrks = SoupX::quickMarkers(toc = combined.obj@assays$RNA@counts, clusters = "integrated_snn_res.0.5")
Error in dimnames(x) <- dn : 
  length of 'dimnames' [1] not equal to array extent
In addition: There were 50 or more warnings (use warnings() to see the first 50)

Could you please help with some hints? Thank you!

constantAmateur commented 2 years ago

Clusters needs to be a vector, not the name of meta.data column in the Seurat object. To run on a seurat object do

mrks = SoupX::quickMarkers(toc = srat@assays$RNA@counts,clusters=srat@meta.data$integrated_snn_res.0.5)