File Pairs as process input, DSL2

42 views
Skip to first unread message

Adam Streck

unread,
Aug 16, 2022, 8:57:19 AM8/16/22
to Nextflow
Consider the example of the Channel.fromFilePairs as given here:

https://www.nextflow.io/docs/latest/channel.html#fromfilepairs

load this data into a variable DATA, i.e. DATA.view() prints:

[SRR493366, [/my/data/SRR493366_1.fastq, /my/data/SRR493366_2.fastq]] [SRR493367, [/my/data/SRR493367_1.fastq, /my/data/SRR493367_2.fastq]] [SRR493368, [/my/data/SRR493368_1.fastq, /my/data/SRR493368_2.fastq]] [SRR493369, [/my/data/SRR493369_1.fastq, /my/data/SRR493369_2.fastq]] [SRR493370, [/my/data/SRR493370_1.fastq, /my/data/SRR493370_2.fastq]] [SRR493371, [/my/data/SRR493371_1.fastq, /my/data/SRR493371_2.fastq]]

how can I create a process that takes DATA as an input? If there was just one file per name, I can do:

input:
tuple val(name), path(file)


however for the two files neither:

input:
tuple val(name), path(file1), path(file2)


nor:

input:
tuple val(name), tuple(path(file1), path(file2))


work.

Harshil Patel

unread,
Aug 16, 2022, 9:53:48 AM8/16/22
to Nextflow

Hi Adam,

Hope you are well! 

This group is no longer officially maintained in favour of using the Nextflow Slack workspace. You can join via the link below and ask any questions in the appropriate channel (e.g. in this case #nextflow-help):
https://www.nextflow.io/slack-invite.html

See you there!

Cheers,

Harshil
Reply all
Reply to author
Forward
0 new messages