Skip to content

Commit

Permalink
Merge branch 'master' into sylph_profile
Browse files Browse the repository at this point in the history
  • Loading branch information
sofstam authored Jan 16, 2025
2 parents bb4bb66 + 070b1ad commit 041ef71
Show file tree
Hide file tree
Showing 13 changed files with 157 additions and 180 deletions.
2 changes: 1 addition & 1 deletion modules/nf-core/seqkit/fx2tab/environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ channels:
- conda-forge
- bioconda
dependencies:
- bioconda::seqkit=2.8.1
- bioconda::seqkit=2.9.0
16 changes: 14 additions & 2 deletions modules/nf-core/seqkit/fx2tab/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ process SEQKIT_FX2TAB {

conda "${moduleDir}/environment.yml"
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/seqkit:2.8.1--h9ee0642_0' :
'biocontainers/seqkit:2.8.1--h9ee0642_0' }"
'https://depot.galaxyproject.org/singularity/seqkit:2.9.0--h9ee0642_0' :
'biocontainers/seqkit:2.9.0--h9ee0642_0' }"

input:
tuple val(meta), path(fastx)
Expand Down Expand Up @@ -34,4 +34,16 @@ process SEQKIT_FX2TAB {
seqkit: \$( seqkit | sed '3!d; s/Version: //' )
END_VERSIONS
"""

stub:
def prefix = task.ext.prefix ?: "${meta.id}"
def suffix = task.ext.suffix ?: "txt.zst"
"""
touch ${prefix}.${suffix}
cat <<-END_VERSIONS > versions.yml
"${task.process}":
seqkit: \$( seqkit | sed '3!d; s/Version: //' )
END_VERSIONS
"""
}
34 changes: 17 additions & 17 deletions modules/nf-core/seqkit/fx2tab/tests/main.nf.test.snap
Original file line number Diff line number Diff line change
Expand Up @@ -7,30 +7,30 @@
{
"id": "test"
},
"test.txt.zst:md5,08902131ebe68052a97178bc426bf944"
"test.txt.zst:md5,d41d8cd98f00b204e9800998ecf8427e"
]
],
"1": [
"versions.yml:md5,ba37c06c2d66e54301b2cd35ae47d0e8"
"versions.yml:md5,b35c25f76ae716eb6bed4f18abf12d50"
],
"text": [
[
{
"id": "test"
},
"test.txt.zst:md5,08902131ebe68052a97178bc426bf944"
"test.txt.zst:md5,d41d8cd98f00b204e9800998ecf8427e"
]
],
"versions": [
"versions.yml:md5,ba37c06c2d66e54301b2cd35ae47d0e8"
"versions.yml:md5,b35c25f76ae716eb6bed4f18abf12d50"
]
}
],
"meta": {
"nf-test": "0.8.4",
"nextflow": "23.10.1"
"nf-test": "0.9.2",
"nextflow": "24.10.3"
},
"timestamp": "2024-05-07T16:01:39.484590737"
"timestamp": "2025-01-15T12:18:24.281141"
},
"sarscov2 - fasta": {
"content": [
Expand All @@ -44,7 +44,7 @@
]
],
"1": [
"versions.yml:md5,ba37c06c2d66e54301b2cd35ae47d0e8"
"versions.yml:md5,b35c25f76ae716eb6bed4f18abf12d50"
],
"text": [
[
Expand All @@ -55,15 +55,15 @@
]
],
"versions": [
"versions.yml:md5,ba37c06c2d66e54301b2cd35ae47d0e8"
"versions.yml:md5,b35c25f76ae716eb6bed4f18abf12d50"
]
}
],
"meta": {
"nf-test": "0.8.4",
"nextflow": "23.10.1"
"nf-test": "0.9.2",
"nextflow": "24.10.3"
},
"timestamp": "2024-05-07T16:01:21.332957847"
"timestamp": "2025-01-15T12:18:14.007765"
},
"sarscov2 - fastq": {
"content": [
Expand All @@ -77,7 +77,7 @@
]
],
"1": [
"versions.yml:md5,ba37c06c2d66e54301b2cd35ae47d0e8"
"versions.yml:md5,b35c25f76ae716eb6bed4f18abf12d50"
],
"text": [
[
Expand All @@ -88,14 +88,14 @@
]
],
"versions": [
"versions.yml:md5,ba37c06c2d66e54301b2cd35ae47d0e8"
"versions.yml:md5,b35c25f76ae716eb6bed4f18abf12d50"
]
}
],
"meta": {
"nf-test": "0.8.4",
"nextflow": "23.10.1"
"nf-test": "0.9.2",
"nextflow": "24.10.3"
},
"timestamp": "2024-05-07T16:01:29.885155029"
"timestamp": "2025-01-15T12:18:19.228692"
}
}
2 changes: 1 addition & 1 deletion modules/nf-core/seqkit/tab2fx/environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ channels:
- conda-forge
- bioconda
dependencies:
- bioconda::seqkit=2.8.1
- bioconda::seqkit=2.9.0
16 changes: 14 additions & 2 deletions modules/nf-core/seqkit/tab2fx/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ process SEQKIT_TAB2FX {

conda "${moduleDir}/environment.yml"
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/seqkit:2.8.1--h9ee0642_0' :
'biocontainers/seqkit:2.8.1--h9ee0642_0' }"
'https://depot.galaxyproject.org/singularity/seqkit:2.9.0--h9ee0642_0' :
'biocontainers/seqkit:2.9.0--h9ee0642_0' }"

input:
tuple val(meta), path(text)
Expand Down Expand Up @@ -34,4 +34,16 @@ process SEQKIT_TAB2FX {
seqkit: \$( seqkit | sed '3!d; s/Version: //' )
END_VERSIONS
"""

stub:
def prefix = task.ext.prefix ?: "${meta.id}"
def suffix = task.ext.suffix ?: "fa.zst"
"""
touch ${prefix}.${suffix}
cat <<-END_VERSIONS > versions.yml
"${task.process}":
seqkit: \$( seqkit | sed '3!d; s/Version: //' )
END_VERSIONS
"""
}
54 changes: 27 additions & 27 deletions modules/nf-core/seqkit/tab2fx/tests/main.nf.test.snap
Original file line number Diff line number Diff line change
Expand Up @@ -7,30 +7,30 @@
{
"id": "test"
},
"test.fa.zst:md5,04d45a85c10933605cb5a289552c83a0"
"test.fa.zst:md5,d41d8cd98f00b204e9800998ecf8427e"
]
],
"1": [
"versions.yml:md5,60fb327ac9a1ed20945fbb049faa7e36"
"versions.yml:md5,d01878090b875a05b111ee8a68405491"
],
"fastx": [
[
{
"id": "test"
},
"test.fa.zst:md5,04d45a85c10933605cb5a289552c83a0"
"test.fa.zst:md5,d41d8cd98f00b204e9800998ecf8427e"
]
],
"versions": [
"versions.yml:md5,60fb327ac9a1ed20945fbb049faa7e36"
"versions.yml:md5,d01878090b875a05b111ee8a68405491"
]
}
],
"meta": {
"nf-test": "0.8.4",
"nextflow": "23.10.1"
"nf-test": "0.9.2",
"nextflow": "24.10.3"
},
"timestamp": "2024-05-08T08:24:24.025365917"
"timestamp": "2025-01-15T12:20:30.19388"
},
"fastq_gz": {
"content": [
Expand All @@ -44,7 +44,7 @@
]
],
"1": [
"versions.yml:md5,60fb327ac9a1ed20945fbb049faa7e36"
"versions.yml:md5,d01878090b875a05b111ee8a68405491"
],
"fastx": [
[
Expand All @@ -55,15 +55,15 @@
]
],
"versions": [
"versions.yml:md5,60fb327ac9a1ed20945fbb049faa7e36"
"versions.yml:md5,d01878090b875a05b111ee8a68405491"
]
}
],
"meta": {
"nf-test": "0.8.4",
"nextflow": "23.10.1"
"nf-test": "0.9.2",
"nextflow": "24.10.3"
},
"timestamp": "2024-05-08T08:24:12.779036251"
"timestamp": "2025-01-15T12:20:25.318142"
},
"fasta_gz": {
"content": [
Expand All @@ -77,7 +77,7 @@
]
],
"1": [
"versions.yml:md5,60fb327ac9a1ed20945fbb049faa7e36"
"versions.yml:md5,d01878090b875a05b111ee8a68405491"
],
"fastx": [
[
Expand All @@ -88,15 +88,15 @@
]
],
"versions": [
"versions.yml:md5,60fb327ac9a1ed20945fbb049faa7e36"
"versions.yml:md5,d01878090b875a05b111ee8a68405491"
]
}
],
"meta": {
"nf-test": "0.8.4",
"nextflow": "23.10.1"
"nf-test": "0.9.2",
"nextflow": "24.10.3"
},
"timestamp": "2024-05-08T08:24:00.497912668"
"timestamp": "2025-01-15T12:20:19.111781"
},
"fasta": {
"content": [
Expand All @@ -110,7 +110,7 @@
]
],
"1": [
"versions.yml:md5,60fb327ac9a1ed20945fbb049faa7e36"
"versions.yml:md5,d01878090b875a05b111ee8a68405491"
],
"fastx": [
[
Expand All @@ -121,15 +121,15 @@
]
],
"versions": [
"versions.yml:md5,60fb327ac9a1ed20945fbb049faa7e36"
"versions.yml:md5,d01878090b875a05b111ee8a68405491"
]
}
],
"meta": {
"nf-test": "0.8.4",
"nextflow": "23.10.1"
"nf-test": "0.9.2",
"nextflow": "24.10.3"
},
"timestamp": "2024-05-08T08:23:31.940090506"
"timestamp": "2025-01-15T12:20:06.405339"
},
"fastq": {
"content": [
Expand All @@ -143,7 +143,7 @@
]
],
"1": [
"versions.yml:md5,60fb327ac9a1ed20945fbb049faa7e36"
"versions.yml:md5,d01878090b875a05b111ee8a68405491"
],
"fastx": [
[
Expand All @@ -154,14 +154,14 @@
]
],
"versions": [
"versions.yml:md5,60fb327ac9a1ed20945fbb049faa7e36"
"versions.yml:md5,d01878090b875a05b111ee8a68405491"
]
}
],
"meta": {
"nf-test": "0.8.4",
"nextflow": "23.10.1"
"nf-test": "0.9.2",
"nextflow": "24.10.3"
},
"timestamp": "2024-05-08T08:23:46.059347765"
"timestamp": "2025-01-15T12:20:12.813847"
}
}
27 changes: 14 additions & 13 deletions subworkflows/nf-core/abundance_differential_filter/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -31,15 +31,16 @@ workflow ABUNDANCE_DIFFERENTIAL_FILTER {

// Set up how the channels crossed below will be used to generate channels for processing
def criteria = multiMapCriteria { meta_input, abundance, analysis_method, fc_threshold, stat_threshold, meta_exp, samplesheet, meta_contrasts, variable, reference, target ->
def meta_for_diff = mergeMaps(meta_contrasts, meta_input) + [ 'method': analysis_method ]
def meta_input_new = meta_input + [ 'method': analysis_method ]
samples_and_matrix:
meta_map = meta_input + [ 'method': analysis_method ]
[meta_map, samplesheet, abundance]
contrasts:
meta_map = mergeMaps(meta_contrasts, meta_input) + [ 'method': analysis_method ]
[ meta_map, variable, reference, target ]
[ meta_input_new, samplesheet, abundance ]
contrasts_for_diff:
[ meta_for_diff, variable, reference, target ]
filter_params:
meta_map = mergeMaps(meta_contrasts, meta_input) + [ 'method': analysis_method ]
[meta_map, [ 'fc_threshold': fc_threshold, 'stat_threshold': stat_threshold ]]
[ meta_for_diff, [ 'fc_threshold': fc_threshold, 'stat_threshold': stat_threshold ]]
contrasts_for_norm:
[ meta_input_new, variable, reference, target ]
}

// For DIFFERENTIAL modules we need to cross the things we're iterating so we
Expand Down Expand Up @@ -70,13 +71,13 @@ workflow ABUNDANCE_DIFFERENTIAL_FILTER {
// LIMMA_NORM directly. It internally runs normalization + DE analysis.

LIMMA_NORM(
norm_inputs.contrasts.filter{it[0].method == 'limma'}.first(),
norm_inputs.contrasts_for_norm.filter{it[0].method == 'limma'},
norm_inputs.samples_and_matrix.filter{it[0].method == 'limma'}
)

LIMMA_DIFFERENTIAL(
inputs.contrasts.filter{it[0].method == 'limma'},
inputs.samples_and_matrix.filter { it[0].method == 'limma' }
inputs.contrasts_for_diff.filter{ it[0].method == 'limma' },
inputs.samples_and_matrix.filter{ it[0].method == 'limma' }
)

// ----------------------------------------------------
Expand All @@ -91,14 +92,14 @@ workflow ABUNDANCE_DIFFERENTIAL_FILTER {
// DESEQ2_NORM directly. It internally runs normalization + DE analysis.

DESEQ2_NORM(
norm_inputs.contrasts.filter{it[0].method == 'deseq2'}.first(),
norm_inputs.contrasts_for_norm.filter{it[0].method == 'deseq2'},
norm_inputs.samples_and_matrix.filter{it[0].method == 'deseq2'},
ch_control_features.first(),
ch_transcript_lengths.first()
)

DESEQ2_DIFFERENTIAL(
inputs.contrasts.filter{it[0].method == 'deseq2'},
inputs.contrasts_for_diff.filter{it[0].method == 'deseq2'},
inputs.samples_and_matrix.filter{it[0].method == 'deseq2'},
ch_control_features.first(),
ch_transcript_lengths.first()
Expand All @@ -112,7 +113,7 @@ workflow ABUNDANCE_DIFFERENTIAL_FILTER {
// not produce a normalized matrix.

PROPR_PROPD(
inputs.contrasts.filter{it[0].method == 'propd'},
inputs.contrasts_for_diff.filter{it[0].method == 'propd'},
inputs.samples_and_matrix.filter { it[0].method == 'propd' }
)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ output:
authors:
- "@pinin4fjords"
- "@bjlang"
- "@araiz2001"
- "@caraiz2001"
- "@suzannejin"
maintainers:
- "@pinin4fjords"
Expand Down
Loading

0 comments on commit 041ef71

Please sign in to comment.