diff --git a/README.md b/README.md index a6dcd2b8..3212f4ef 100644 --- a/README.md +++ b/README.md @@ -1,15 +1,16 @@ -[![DOI](https://zenodo.org/badge/DOI/10.5281/zenodo.3997375.svg)](https://doi.org/10.5281/zenodo.3445485) -[![Releases](https://img.shields.io/github/v/release/fmalmeida/mpgap)](https://github.com/fmalmeida/mpgap/releases) +[![F1000 Paper](https://img.shields.io/badge/Citation%20F1000-10.12688/f1000research.139488.1-orange)](https://doi.org/10.12688/f1000research.139488.1) +[![GitHub release (latest by date including pre-releases)](https://img.shields.io/github/v/release/fmalmeida/mpgap?include_prereleases&label=Latest%20release)](https://github.com/fmalmeida/mpgap/releases) [![Documentation](https://img.shields.io/badge/Documentation-readthedocs-brightgreen)](https://mpgap.readthedocs.io/en/latest/?badge=latest) -[![Dockerhub](https://img.shields.io/badge/Docker-fmalmeida/mpgap-informational)](https://hub.docker.com/r/fmalmeida/mpgap) -[![Nextflow](https://img.shields.io/badge/nextflow%20DSL2-%E2%89%A521.04.0-23aa62.svg?labelColor=000000)](https://www.nextflow.io/) -[![run with conda](http://img.shields.io/badge/run%20with-conda-3EB049?labelColor=000000&logo=anaconda)](https://docs.conda.io/en/latest/) +[![Nextflow](https://img.shields.io/badge/nextflow%20DSL2-%E2%89%A521.10.3-23aa62.svg?labelColor=000000)](https://www.nextflow.io/) [![run with docker](https://img.shields.io/badge/run%20with-docker-0db7ed?labelColor=000000&logo=docker)](https://www.docker.com/) [![run with singularity](https://img.shields.io/badge/run%20with-singularity-1d355c.svg?labelColor=000000)](https://sylabs.io/docs/) -[![Follow on Twitter](http://img.shields.io/badge/twitter-%40fmarquesalmeida-1DA1F2?labelColor=000000&logo=twitter)](https://twitter.com/fmarquesalmeida) [![License](https://img.shields.io/badge/License-GPL%203-black)](https://github.com/fmalmeida/mpgap/blob/master/LICENSE) +[![Follow on Twitter](http://img.shields.io/badge/twitter-%40fmarquesalmeida-1DA1F2?labelColor=000000&logo=twitter)](https://twitter.com/fmarquesalmeida) +[![Zenodo Archive](https://img.shields.io/badge/Zenodo-Archive-blue)](https://doi.org/10.5281/zenodo.3445485) + +[![Open in Gitpod](https://gitpod.io/button/open-in-gitpod.svg)](https://gitpod.io/github.com/fmalmeida/mpgap)

@@ -290,7 +291,11 @@ It will result in the following: ## Citation -To cite this tool please refer to our [Zenodo tag](https://doi.org/10.5281/zenodo.3445485). +In order to cite this pipeline, please refer to: + +> Almeida FMd, Campos TAd and Pappas Jr GJ. Scalable and versatile container-based pipelines for de novo genome assembly and bacterial annotation. [version 1; peer review: awaiting peer review]. F1000Research 2023, 12:1205 (https://doi.org/10.12688/f1000research.139488.1) + +Additionally, archived versions of the pipeline are also found in [Zenodo](https://doi.org/10.5281/zenodo.3445485). This pipeline uses code and infrastructure developed and maintained by the [nf-core](https://nf-co.re) community, reused here under the [GPLv3](https://github.com/fmalmeida/ngs-preprocess/blob/master/LICENSE). diff --git a/docs/index.rst b/docs/index.rst index c702a3af..43eae057 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -45,6 +45,15 @@ It wraps up the following tools: manual config +Citation +-------- + +In order to cite this pipeline, please refer to: + +> Almeida FMd, Campos TAd and Pappas Jr GJ. Scalable and versatile container-based pipelines for de novo genome assembly and bacterial annotation. [version 1; peer review: awaiting peer review]. F1000Research 2023, 12:1205 (https://doi.org/10.12688/f1000research.139488.1) + +Additionally, archived versions of the pipeline are also found in `Zenodo `_. + Support Contact --------------- Whenever a doubt arise feel free to contact me at almeidafmarques@gmail.com diff --git a/lib/WorkflowMain.groovy b/lib/WorkflowMain.groovy index 82315f90..c856e6ae 100755 --- a/lib/WorkflowMain.groovy +++ b/lib/WorkflowMain.groovy @@ -10,7 +10,7 @@ class WorkflowMain { public static String citation(workflow) { return "If you use ${workflow.manifest.name} for your analysis please cite:\n\n" + "* The pipeline\n" + - " https://doi.org/10.5281/zenodo.3445485\n\n" + + " https://doi.org/10.12688/f1000research.139488.1\n\n" + "* The nf-core framework\n" + " https://doi.org/10.1038/s41587-020-0439-x\n\n" + "* Software dependencies\n" + diff --git a/markdown/CHANGELOG.md b/markdown/CHANGELOG.md index a1ba5af4..22f36d55 100644 --- a/markdown/CHANGELOG.md +++ b/markdown/CHANGELOG.md @@ -6,6 +6,7 @@ The tracking for changes started in v2. * Update unicyler to v0.5.0 * Adjust Pilon polishing module to select how many rounds of poloshing to run. Default is 4. +* Add a directory called `final_assemblies` in the main output directory holding all the assemblies generated in the pipeline execution. ## v3.1.4 -- [2022-Sep-03] diff --git a/modules/QualityAssessment/quast.nf b/modules/QualityAssessment/quast.nf index c8431aeb..b7ecb5f3 100644 --- a/modules/QualityAssessment/quast.nf +++ b/modules/QualityAssessment/quast.nf @@ -1,12 +1,16 @@ process quast { - publishDir "${params.output}/${prefix}/00_quality_assessment", mode: 'copy' + publishDir "${params.output}", mode: 'copy', saveAs: { filename -> + if ( filename.tokenize('/').contains('input_assembly') ) "final_assemblies/${id}_${filename.tokenize('/')[1]}" + else "${prefix}/00_quality_assessment/${filename}" + } tag "${id}" input: tuple val(id), file(contigs), val(assembler), val(entrypoint), file(sread1), file(sread2), file(single), file(lreads), val(lr_type), val(wtdbg2_technology), val(genome_size), val(corrected_long_reads), val(medaka_model), file(fast5), val(nanopolish_max_haplotypes), val(shasta_config), file(bams), val(prefix) output: - tuple val(prefix), file("${assembler}") + tuple val(id), val(entrypoint), val(prefix), file("${assembler}"), emit: results + file("input_assembly/*") script: // Alignment parameters @@ -29,6 +33,10 @@ process quast { --min-contig 100 \\ $additional_params \\ ${contigs} + + # save assembly + mkdir -p input_assembly + cp ${contigs} input_assembly/${contigs} """ else if (params.selected_profile == "singularity") @@ -49,5 +57,9 @@ process quast { --min-contig 100 \\ $additional_params \\ ${contigs} + + # save assembly + mkdir -p input_assembly + cp ${contigs} input_assembly/${contigs} """ } diff --git a/workflows/assembly_qc.nf b/workflows/assembly_qc.nf index 9b09b7a8..5190e488 100644 --- a/workflows/assembly_qc.nf +++ b/workflows/assembly_qc.nf @@ -18,9 +18,6 @@ workflow ASSEMBLY_QC { quast(input_tuple) // Run multiqc - multiqc( - quast.out.groupTuple(), - Channel.value("$workflow.runName") - ) + multiqc(quast.out.results.groupTuple(by: [0,1,2]), Channel.value("$workflow.runName")) } diff --git a/workflows/hybrid.nf b/workflows/hybrid.nf index 7bd7d313..d068bd01 100644 --- a/workflows/hybrid.nf +++ b/workflows/hybrid.nf @@ -111,10 +111,13 @@ workflow HYBRID { } // Get hybrid assemblies - HYBRID_OUTPUTS['ASSEMBLIES'] = HYBRID_OUTPUTS['SPADES'] - .mix(HYBRID_OUTPUTS['UNICYCLER'], - HYBRID_OUTPUTS['HASLR']) - .combine(input_tuple, by: 0) + HYBRID_OUTPUTS['ASSEMBLIES'] = + HYBRID_OUTPUTS['SPADES'] + .mix( + HYBRID_OUTPUTS['UNICYCLER'], + HYBRID_OUTPUTS['HASLR'] + ) + .combine(input_tuple, by: 0) /* * Polish a long reads assembly @@ -169,13 +172,16 @@ workflow HYBRID { } // Get long reads assemblies - LONGREADS_OUTPUTS['RAW_ASSEMBLIES'] = LONGREADS_OUTPUTS['CANU'] - .mix(LONGREADS_OUTPUTS['FLYE'], - LONGREADS_OUTPUTS['UNICYCLER'], - LONGREADS_OUTPUTS['RAVEN'], - LONGREADS_OUTPUTS['WTDBG2'], - LONGREADS_OUTPUTS['SHASTA']) - .combine(input_tuple, by: 0) + LONGREADS_OUTPUTS['RAW_ASSEMBLIES'] = + LONGREADS_OUTPUTS['CANU'] + .mix( + LONGREADS_OUTPUTS['FLYE'], + LONGREADS_OUTPUTS['UNICYCLER'], + LONGREADS_OUTPUTS['RAVEN'], + LONGREADS_OUTPUTS['WTDBG2'], + LONGREADS_OUTPUTS['SHASTA'] + ) + .combine(input_tuple, by: 0) /* * Run medaka? @@ -196,10 +202,13 @@ workflow HYBRID { LONGREADS_OUTPUTS['GCPP'] = strategy_2_gcpp.out[1] // Gather long reads assemblies polished - LONGREADS_OUTPUTS['POLISHED_ASSEMBLIES'] = LONGREADS_OUTPUTS['MEDAKA'] - .mix(LONGREADS_OUTPUTS['NANOPOLISH'], - LONGREADS_OUTPUTS['GCPP']) - .combine(input_tuple, by: 0) + LONGREADS_OUTPUTS['POLISHED_ASSEMBLIES'] = + LONGREADS_OUTPUTS['MEDAKA'] + .mix( + LONGREADS_OUTPUTS['NANOPOLISH'], + LONGREADS_OUTPUTS['GCPP'] + ) + .combine(input_tuple, by: 0) /* * Finally, run sreads polish for all