Skip to content

Commit 29f9458

Browse files
committed
fix cell clustering bug
1 parent 14081c6 commit 29f9458

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

R/bambu.R

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -266,7 +266,7 @@ bambu <- function(reads, annotations = NULL, genome = NULL, NDR = NULL,
266266
#load in the barcode clustering from file if provided
267267
iter <- seq_len(ncol(metadata(quantData_i)$countMatrix)) # iter is integer
268268
if(!is.null(clusters)){
269-
if(class(clusters[[i]])!="CompressedCharacterList"){ # !is.list(clusters) is FALSE for CompressedCharacterList
269+
if(class(clusters)!="CompressedCharacterList"&(!is.list(clusters))){
270270
clusterMaps <- NULL
271271
for(j in seq_along(metadata(quantData_i)$sampleNames)){ #load in a file per sample name provided
272272
clusterMap <- fread(clusters[[j]], header = FALSE,
@@ -287,7 +287,7 @@ bambu <- function(reads, annotations = NULL, genome = NULL, NDR = NULL,
287287
if(length(quantData)>1){
288288
iter <- clusters[[i]] #lowMemory mode
289289
}else{
290-
iter <- clusters#do.call(c,clusters)
290+
iter <- do.call(c,clusters) #clusters direct assignment in Multiplex_Major_Patch is throwing error
291291
}
292292
}
293293
}

0 commit comments

Comments
 (0)