Skip to content

Commit

Permalink
get the skipping steps working partly
Browse files Browse the repository at this point in the history
  • Loading branch information
cjfields committed Jan 10, 2025
1 parent bbc7064 commit a924ade
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 24 deletions.
48 changes: 28 additions & 20 deletions subworkflows/local/pre_qc.nf
Original file line number Diff line number Diff line change
Expand Up @@ -14,35 +14,43 @@ workflow PRE_QC {

take:
ch_samplesheet
skip_ee
skip_merging
skip_dadaQC

main:
ch_versions = Channel.empty()

VSEARCH_OVERLAP(
ch_samplesheet
)
if (!skip_merging) {
VSEARCH_OVERLAP(
ch_samplesheet
)

ch_versions = ch_versions.mix(VSEARCH_OVERLAP.out.versions.first())
ch_versions = ch_versions.mix(VSEARCH_OVERLAP.out.versions.first())
MERGE_OVERLAP_CHECK(
VSEARCH_OVERLAP.out.merged_log.collect()
)

VSEARCH_EESTATS (
ch_samplesheet
)
OVERLAP_HEATMAP(
VSEARCH_OVERLAP.out.merged_stats.collect()
)
}

ch_versions = ch_versions.mix(VSEARCH_EESTATS.out.versions.first())
if (!skip_ee) {
VSEARCH_EESTATS (
ch_samplesheet
)

MERGE_OVERLAP_CHECK(
VSEARCH_OVERLAP.out.merged_log.collect()
)

OVERLAP_HEATMAP(
VSEARCH_OVERLAP.out.merged_stats.collect()
)

PLOT_QUALITY_PROFILE (
ch_samplesheet
)
ch_versions = ch_versions.mix(VSEARCH_EESTATS.out.versions.first())
}

if (!skip_dadaQC) {
PLOT_QUALITY_PROFILE (
ch_samplesheet
)

ch_versions = ch_versions.mix(PLOT_QUALITY_PROFILE.out.versions.first())
ch_versions = ch_versions.mix(PLOT_QUALITY_PROFILE.out.versions.first())
}

emit:
versions = ch_versions // channel: [ versions.yml ]
Expand Down
11 changes: 7 additions & 4 deletions workflows/tada.nf
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,10 @@ workflow TADA {
ch_versions = ch_versions.mix(FASTQC.out.versions.first())

PRE_QC(
ch_samplesheet
ch_samplesheet,
params.skip_ee,
params.skip_merging,
params.skip_dadaQC
)

ch_versions = ch_versions.mix(PRE_QC.out.versions)
Expand Down Expand Up @@ -167,12 +170,12 @@ workflow TADA {
// would be useful for...
// this needs to die with an error message if method is not defined, or
// it needs to be caught above
if (params.run_tree == 'phangorn') {
if (params.phylo_tool == 'phangorn') {
PHANGORN(
DECIPHER.out.alignment
)
ch_tree = PHANGORN.out.treeGTR
} else if (params.run_tree == 'fasttree') {
} else if (params.phylo_tool == 'fasttree') {
FASTTREE(
DECIPHER.out.alignment
)
Expand All @@ -181,7 +184,7 @@ workflow TADA {

ROOT_TREE(
ch_tree,
params.run_tree
params.phylo_tool
)

// QC
Expand Down

0 comments on commit a924ade

Please sign in to comment.