carmonalab / UCell

Gene set scoring for single-cell data
GNU General Public License v3.0
135 stars 16 forks source link

I found an interesting bug #10

Closed chuiqin closed 2 years ago

chuiqin commented 3 years ago

I would get this error when I run ScoreSignatures_UCell function with these cell count number, such as 1001, 2001, 3001, 4001, 5001, 6001, 7001, 8001, 9001, 10001 and so on. the error:

> scores <- ScoreSignatures_UCell(pbmc3k.final@assays$RNA@counts[,1:10001], features=gene.sets)
Error in setkeyv(x, cols, verbose = verbose, physical = physical) : 
  some columns are not in the data.table: rn

But I run ScoreSignatures_UCell function sucessfully if the cell count number is 101, 102, 110, 1002, 1011, 10002, 10011 and so on.

> scores <- ScoreSignatures_UCell(pbmc3k.final@assays$RNA@counts[,1:10011], features=gene.sets)
> scores <- ScoreSignatures_UCell(pbmc3k.final@assays$RNA@counts[,1:10002], features=gene.sets)

Can you help me with this problem?

mass-a commented 3 years ago

Hello Chuiqin,

thanks for reporting this bug. UCell processes datasets in blocks of n cells (given by the chunk.size parameter) – there was an issue occurring when the last block contained only one cell (e.g. with 1001 or 2001 cells), which should now be solved in the latest version.

Let us know if this works for you. Cheers, -m