diff --git a/modules/nf-core/spaceranger/count/main.nf b/modules/nf-core/spaceranger/count/main.nf index f33d82fcc7e..efbb1b9c734 100644 --- a/modules/nf-core/spaceranger/count/main.nf +++ b/modules/nf-core/spaceranger/count/main.nf @@ -31,17 +31,23 @@ process SPACERANGER_COUNT { def cytaimage = cytaimage ? "--cytaimage=\"${cytaimage}\"" : "" def darkimage = darkimage ? "--darkimage=\"${darkimage}\"" : "" def colorizedimage = colorizedimage ? "--colorizedimage=\"${colorizedimage}\"" : "" + def slide = meta.slide ? meta.slide : "" + def area = meta.area ? meta.area : "" + if (slide.matches("visium-(.*)") && area == "" && slidefile == "") { + slide_and_area = "--unknown-slide=\"${slide}\"" + } else { + slide_and_area = "--slide=\"${slide}\" --area=\"${area}\"" + } """ spaceranger count \\ --id="${prefix}" \\ --sample="${meta.id}" \\ --fastqs=. \\ - --slide="${meta.slide}" \\ - --area="${meta.area}" \\ --transcriptome="${reference}" \\ --localcores=${task.cpus} \\ --localmem=${task.memory.toGiga()} \\ $image $cytaimage $darkimage $colorizedimage \\ + $slide_and_area \\ $probeset \\ $alignment \\ $slidefile \\