how to use #nextflow "multiMap' to transform a channel if the 'input' of an existing module doesn't fit your needs.
eg: you want
tuple val(meta), path(bam),path(bed)
while the module was designed the following way:
tuple val(meta1), path(bed)
tuple val(meta2), path(bam)
https://gist.github.com/lindenb/fbd76e5887754a7831d95422ea58f499
thanks a lot @mbp for the tip !