Update METAPHLAN3/MERGEMETAPHLANTABLES (#2041)

* Update main.nf

* Update meta.yml

* Re-add logos as not staged in a way that works with MultiQC config files

* Add meta to mergemetaphlan3 tables

* Actually combine the data together
This commit is contained in:
James A. Fellows Yates 2022-09-13 14:37:46 +02:00 committed by GitHub
parent ee0346b4d1
commit 36bcd675ae
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 17 additions and 7 deletions

View file

@ -7,10 +7,10 @@ process METAPHLAN3_MERGEMETAPHLANTABLES {
'quay.io/biocontainers/metaphlan:3.0.12--pyhb7b1952_0' }"
input:
path(profiles)
tuple val(meta), path(profiles)
output:
tuple path("${prefix}.txt") , emit: txt
tuple val(meta), path("${prefix}.txt") , emit: txt
path "versions.yml" , emit: versions
when:
@ -18,7 +18,7 @@ process METAPHLAN3_MERGEMETAPHLANTABLES {
script:
def args = task.ext.args ?: ''
prefix = task.ext.prefix ?: "merged_abundance_table"
prefix = task.ext.prefix ?: "${meta.id}"
"""
merge_metaphlan_tables.py \\
$args \\

View file

@ -15,12 +15,22 @@ tools:
licence: ["MIT License"]
input:
- meta:
type: map
description: |
Groovy Map containing sample information
e.g. [ id:'test', single_end:false ]
- profiles:
type: file
description: List of per-sample MetaPhlAn3 taxonomic abundance tables
pattern: "*"
output:
- meta:
type: map
description: |
Groovy Map containing sample information
e.g. [ id:'test', single_end:false ]
- versions:
type: file
description: File containing software versions

View file

@ -17,6 +17,6 @@ workflow test_metaphlan3_mergemetaphlantables {
UNTAR ( db )
METAPHLAN3 ( input, UNTAR.out.untar.map{ it[1] } )
METAPHLAN3_MERGEMETAPHLANTABLES ( METAPHLAN3.out.profile.map{it[1]}.collect() )
METAPHLAN3_MERGEMETAPHLANTABLES ( METAPHLAN3.out.profile.map{ [[id:"test"], it[1]] }.groupTuple() )
}

View file

@ -1,8 +1,8 @@
- name: metaphlan3 mergemetaphlantables test_metaphlan3_mergemetaphlantables
command: nextflow run ./tests/modules/metaphlan3/mergemetaphlantables -entry test_metaphlan3_mergemetaphlantables -c ./tests/config/nextflow.config -c ./tests/modules/metaphlan3/mergemetaphlantables/nextflow.config
tags:
- metaphlan3
- metaphlan3/mergemetaphlantables
- metaphlan3
files:
- path: output/metaphlan3/merged_abundance_table.txt
- path: output/metaphlan3/test.txt
contains: ["clade_name NCBI_tax_id"]