-
Notifications
You must be signed in to change notification settings - Fork 37
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
Bracken output report addition #379
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me but I've made a suggestion for making it more concise. you need to update the changelog too :)
conf/modules.config
Outdated
[ | ||
path: { "${params.outdir}/bracken/${meta.db_name}/" }, | ||
mode: params.publish_dir_mode, | ||
pattern: '*bracken.kraken2.report_bracken*.txt' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's is not worth making it optional with a flag, it would be more concise to just update the glob in the tsv
output e.g. with an OR statement
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Aha! I wasn't aware that was possible. Is the syntax simply pattern: 'x' OR 'y'?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess perhaps you mean '*{txt,tsv}'?
Made changes to the |
|
conf/modules.config
Outdated
mode: params.publish_dir_mode, | ||
pattern: '*bracken.kraken2.report_bracken*.txt' | ||
] | ||
pattern: '*{.tsv,.report_bracken_species.txt}' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is the .report_bracken_species
infix really necessary? What if the pattern is only *.{txt,tsv}
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is necessary, as the report from Kraken2 (the uncorrected one) also has the .txt
suffix
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nextflow already knows not to pick up input files :), so actually txt,tsv
shoudl be sufficient
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah that is great! Learn something new every day!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe something like?
pattern: '*{.tsv, txt}'
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I just did a test, and it's not working.
I realise now is that is because Nextflow doesn't list teh 'corrected' kraken report in it's output channels
This will require a PR to the nf-core/moduels repo to add the txt
, and then once that's merged in, this PR will need up update the module in the PR in addition to the modules glob.
Sorry this is a bit more involved @hkaspersen ! But hopefully good practise :)
No worries, there is no rush! |
updated bracken module
Thanks for adding this @hkaspersen There is a conflict in |
…profiler into bracken_output_report_fix
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Made a couple more very minor changes (mainly adding the file to the output docs), but otherwise I think we are GTG now! Thank you very much @hkaspersen, we look forward to further contributions from you 😉 !!!
PR checklist
nf-core lint
).nextflow run . -profile test,docker --outdir <OUTDIR>
).docs/usage.md
is updated.docs/output.md
is updated.CHANGELOG.md
is updated.README.md
is updated (including new tool citations and authors/contributors).I added the corrected kraken2 report from Bracken as output, as it was missing from the Bracken output. This file is used for downstream analyses of the corrected counts for each taxa, and it would be very nice to add this as output.