-
Notifications
You must be signed in to change notification settings - Fork 34
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
Add support for generating mag samplesheet #544
base: dev
Are you sure you want to change the base?
Conversation
} | ||
.tap { ch_colnames } | ||
|
||
channelToSamplesheet(ch_colnames, ch_list_for_samplesheet, 'downstream_samplesheets', format, format_sep) |
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.
Joon has updated the function to also include the pipeline name as an additional argument, please check detaxier for the example (this will be helpful when @LilyAnderssonLee 's differentialabundance PR comes in :)
def short_reads_1 = file(params.outdir).toString() + '/' + meta.id + '/' + fastq_1.getName() | ||
def short_reads_2 = file(params.outdir).toString() + '/' + meta.id + '/' + fastq_2.getName() |
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.
Can you not also make this support single_end using the meta.single_end
information?
Or have we lost that information at this stage?
def short_reads_1 = file(params.outdir).toString() + '/' + meta.id + '/' + fastq_1.getName() | |
def short_reads_2 = file(params.outdir).toString() + '/' + meta.id + '/' + fastq_2.getName() | |
def short_reads_1 = file(params.outdir).toString() + '/' + meta.id + '/' + fastq_1.getName() | |
def short_reads_2 = !meta.single_end ? file(params.outdir).toString() + '/' + meta.id + '/' + fastq_2.getName() : "" |
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 do not follow here. We said to filter out the single ends and fasta. Or do I misunderstand something?
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 yeah, good point I forgot and there wasn't a comment why 😅
Please leave a comment next to the line saying only PE supported now, and I'll look into fixing that later :)
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.
@sofstam did you see what @Joon-Klaps did in detaxizer for SE/PE reads? You can copy the same concept here too (basically to branch SE/PE separately, and call the channelToSamplesheet
function twice ;)
Co-authored-by: James A. Fellows Yates <[email protected]>
…profiler into generate-samplesheet
@nf-core-bot fix linting |
|
docs/output.md
Outdated
<summary>Output files</summary> | ||
|
||
- `downstream_samplesheets/` | ||
- `mag.csv`: input sheet for nf-core/mag with paths to nf-core/taxprofiler preprocessed (corresponding to what is saved with `--save_analysis_ready_fastqs`) |
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.
Missing differential abundance? @LilyAnderssonLee do you thin kyou could merge your PR into this one at this stage?
def short_reads_1 = file(params.outdir).toString() + '/' + meta.id + '/' + fastq_1.getName() | ||
def short_reads_2 = file(params.outdir).toString() + '/' + meta.id + '/' + fastq_2.getName() |
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.
@sofstam did you see what @Joon-Klaps did in detaxizer for SE/PE reads? You can copy the same concept here too (basically to branch SE/PE separately, and call the channelToSamplesheet
function twice ;)
subworkflows/local/generate_downstream_samplesheets/tests/main.nf.test
Outdated
Show resolved
Hide resolved
Co-authored-by: James A. Fellows Yates <[email protected]>
Co-authored-by: James A. Fellows Yates <[email protected]>
…profiler into generate-samplesheet
@nf-core-bot fix linting |
docs/output.md
Outdated
@@ -758,7 +758,9 @@ The pipeline can also generate input files for the following downstream pipeline | |||
<summary>Output files</summary> | |||
|
|||
- `downstream_samplesheets/` | |||
- `mag.csv`: input sheet for that contains paths to preprocessed FASTQs (corresponding to what is saved with `--save_analysis_ready_fastqs`) that can be used to skip read preprocessing steps in nf-core/mag | |||
- `mag-{pe,se}.csv`: input sheet for single-end and paired-end reads that contains paths to preprocessed short-read FASTQs (corresponding to what is saved with `--save_analysis_ready_fastqs`) that can be used to skip read preprocessing steps in nf-core/mag. | |||
- Note: if you merge reads, these will be listed in teh `mag-se.csv`. |
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.
Cannot make a suggestion but:
teh mag-se.csv
. -> the mag-se.csv
.
pe: true | ||
} | ||
pe: it.short_reads_2 != "" | ||
unknown: true |
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.
Why is the unknown: true
here?
I think we are almost there, for some reason we get extra files in |
Closes #542
PR checklist
nf-core lint
).nextflow run . -profile test,docker --outdir <OUTDIR>
).nextflow run . -profile debug,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).