Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Nextflow review @bobturneruk ep3, tuple definition #119

Open
ggrimes opened this issue Apr 23, 2024 · 1 comment
Open

Nextflow review @bobturneruk ep3, tuple definition #119

ggrimes opened this issue Apr 23, 2024 · 1 comment

Comments

@ggrimes
Copy link
Collaborator

ggrimes commented Apr 23, 2024

I'm not clear on how a tuple is defined here.

It's introduced as "a grouping of data, represented as a Groovy List" - could it be called a list?

The Nextflow docs really only talk about tuples in the fromFilePairs section "The matching files are emitted as tuples".

Maybe there is an important distinction, but I'm a bit confused.

I see Tuples are defined here https://www.nextflow.io/docs/latest/process.html#input-type-tuple and in the lesson here

https://carpentries-incubator.github.io/workflows-nextflow/05-processes-part2.html#grouped-inputs-and-outputs

@ggrimes
Copy link
Collaborator Author

ggrimes commented Apr 23, 2024

I agree it is confusing.

In Nextflow, tuples are preferred over lists because they ensure data remains unchanged and grouped correctly as it passes through various steps of a pipeline, thanks to their immutable and fixed-size nature. This helps maintain data integrity and simplifies the management of complex workflows.

https://blog.mrhaki.com/2016/03/groovy-goodness-using-tuples.html

I will have a go at rewording

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant