Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
56 changes: 56 additions & 0 deletions subworkflows/local/convert.nf
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@

/*
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
IMPORT LOCAL MODULES
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
*/

include { CONVERT_ADAPTIVE } from '../../modules/local/convert/convert_adaptive'
include { PSEUDOBULK_CELLRANGER } from '../../modules/local/convert/pseudobulk_cellranger'
include { PSEUDOBULK_PHENOTYPE_CELLRANGER } from '../../modules/local/convert/pseudobulk_phenotype_cellranger'

/*
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
RUN MAIN SUBWORKFLOW
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
*/

workflow CONVERT {
take:
sample_map
input_format

main:
pseudobulk_phenotype_files = channel.empty() // Initialize empty channel for phenotype files

if (input_format == 'adaptive') {
CONVERT_ADAPTIVE(
sample_map,
file(params.airr_schema),
file(params.imgt_lookup)
)
sample_map_converted = CONVERT_ADAPTIVE.out.adaptive_convert

} else if (input_format == 'cellranger') {
PSEUDOBULK_CELLRANGER(
sample_map,
file(params.airr_schema)
)
sample_map_converted = PSEUDOBULK_CELLRANGER.out.cellranger_pseudobulk

if (params.sobject_gex) {
PSEUDOBULK_PHENOTYPE_CELLRANGER(
sample_map,
file(params.airr_schema),
file(params.sobject_gex)
)
pseudobulk_phenotype_files = PSEUDOBULK_PHENOTYPE_CELLRANGER.out.cellranger_pseudobulk_phenotype
}
} else {
sample_map_converted = sample_map
}

emit:
sample_map_converted
pseudobulk_phenotype_files
}
16 changes: 0 additions & 16 deletions subworkflows/local/convert/adaptive.nf

This file was deleted.

45 changes: 0 additions & 45 deletions subworkflows/local/convert/main.nf

This file was deleted.

15 changes: 0 additions & 15 deletions subworkflows/local/convert/pseudobulk_cellranger.nf

This file was deleted.

17 changes: 0 additions & 17 deletions subworkflows/local/convert/pseudobulk_phenotype.nf

This file was deleted.

Loading