Skip to content

Commit

Permalink
Merge pull request #383 from WrightonLabCSU/bugfix/define_distill_sql…
Browse files Browse the repository at this point in the history
…_script_default

Give default to ch_distill_sql_script since it is used always in annotations
  • Loading branch information
madeline-scyphers authored Nov 4, 2024
2 parents c94d0d4 + 332cb27 commit 5b8527f
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 13 deletions.
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -250,12 +250,12 @@ Additionally, `--merge-annotations` and `--rename` can be run idenpendently of a
1) **Rename fasta headers based on input sample file names:**
`nextflow run DRAM --rename --input_fasta_dir <path/to/fasta/directory/>`
`nextflow run DRAM --rename --input_fasta <path/to/fasta/directory/>`
2) **Call genes using input fastas (use --rename to rename FASTA headers):**
`nextflow run DRAM --call --rename --input_fasta_dir <path/to/fasta/directory/>`
`nextflow run DRAM --call --rename --input_fasta <path/to/fasta/directory/>`
3) **Annotate called genes using input called genes and the KOFAM database:**
Expand Down Expand Up @@ -285,7 +285,7 @@ Additionally, `--merge-annotations` and `--rename` can be run idenpendently of a
8) **Call and Annotate genes using input fastas and KOFAM database. Distill using the default topic and the AG ecosystem:**
`nextflow run DRAM --input_fasta_dir <path/to/fasta/directory/> --outdir <path/to/output/directory/> --call --annotate --distill_topic default --distill_ecosystem ag --threads <threads> --use_kofam`
`nextflow run DRAM --input_fasta <path/to/fasta/directory/> --outdir <path/to/output/directory/> --call --annotate --distill_topic default --distill_ecosystem ag --threads <threads> --use_kofam`
9) **"Real-world" example using the test data provided in this repository:**
Expand Down Expand Up @@ -334,7 +334,7 @@ DRAM
nextflow run DRAM --rename --call --annotate --use_<database(s) --distill_topic <distillate(s)>
Call genes using input fastas (use --rename to rename FASTA headers):
nextflow run DRAM --call --rename --input_fasta_dir <path/to/fasta/directory/>
nextflow run DRAM --call --rename --input_fasta <path/to/fasta/directory/>
Annotate called genes using input fastas:
nextflow run DRAM --annotate --input_genes <path/to/called/genes/directory>
Expand Down Expand Up @@ -465,7 +465,7 @@ DRAM
Usage:
Call genes using input fastas:
nextflow run DRAM --call --input_fasta_dir <path/to/fasta/directory/> --outdir <path/to/output/directory/> --threads <threads>
nextflow run DRAM --call --input_fasta <path/to/fasta/directory/> --outdir <path/to/output/directory/> --threads <threads>
REQUIRED DRAM profile options:
-profile STRING <conda, conda_slurm, singularity, singularity_conda>
Expand Down Expand Up @@ -587,7 +587,7 @@ DRAM
Example:
Call and Annotate genes using input fastas and KOFAM database. Distill using carbon topic and AG ecosystem:
nextflow run DRAM --input_fasta_dir <path/to/fasta/directory/> --outdir <path/to/output/directory/> --call --annotate --distill_topic carbon --distill_ecosystem ag --threads <threads> --use_kofam
nextflow run DRAM --input_fasta <path/to/fasta/directory/> --outdir <path/to/output/directory/> --call --annotate --distill_topic carbon --distill_ecosystem ag --threads <threads> --use_kofam
REQUIRED DRAM profile options:
-profile STRING <conda, conda_slurm, singularity, singularity_conda>
Expand Down
20 changes: 16 additions & 4 deletions main.nf
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
DRAM: DRAM (Distilled and Refined Annotation of Metabolism Version 2) is a tool for annotating metagenomic assembled genomes.
DRAM: DRAM (Distilled and Refined Annotation of Metabolism) is a tool for annotating metagenomic assembled genomes.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Homepage of project
Expand Down Expand Up @@ -458,6 +458,20 @@ if( params.use_dbset == "adjectives_set" ){
// channels for the various annotation databases
def annotate_list = ""

/*
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Defaults for all processes
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
*/

ch_distill_sql_script = file(params.distill_sql_script)

/*
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
specific process stuff
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
*/

if( params.annotate ){
//This is just temporary - want these in the containers eventually
ch_combine_annot_script = file(params.combine_annotations_script)
Expand Down Expand Up @@ -685,7 +699,6 @@ if (params.distill_topic != "" || params.distill_ecosystem != "" || params.disti
distill_flag = "on"
// Set channels for supporting python scripts - will be moved to container eventually
ch_distill_xlsx_script = file(params.distill_xlsx_script)
ch_distill_sql_script = file(params.distill_sql_script)

// Ensure rRNA and tRNA channels are populated if the user is not calling genes
if( params.call == 0 ){
Expand Down Expand Up @@ -742,8 +755,7 @@ if( params.trees ) {

ch_count_annots_script = file(params.count_annots_script)
ch_distill_xlsx_script = file(params.distill_xlsx_script)
ch_distill_sql_script = file(params.distill_sql_script)


//Add in option for --add_trees <list of paths to trees refpkg directories>
if( params.add_trees ){
ch_add_trees = file(params.add_trees).exists() ? file(params.add_trees) : error("Error: If using --add_trees, you must supply a path to a directory containing each tree subdirectory. Additional trees directory not found at ${params.add_trees}")
Expand Down
6 changes: 3 additions & 3 deletions modules/utils/help.nf
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ Usage:
nextflow run $workflow.manifest.name --rename --call --annotate --use_<database(s) --distill_topic <distillate(s)>
Call genes using input fastas (use --rename to rename FASTA headers):
nextflow run $workflow.manifest.name --call --rename --input_fasta_dir <path/to/fasta/directory/>
nextflow run $workflow.manifest.name --call --rename --input_fasta <path/to/fasta/directory/>
Annotate called genes using input fastas:
nextflow run $workflow.manifest.name --annotate --input_genes <path/to/called/genes/directory>
Expand Down Expand Up @@ -276,7 +276,7 @@ Call description: The purpose of $workflow.manifest.name --call is to call genes
Usage:
Call genes using input fastas:
nextflow run $workflow.manifest.name --call --input_fasta_dir <path/to/fasta/directory/> --outdir <path/to/output/directory/> --threads <threads>
nextflow run $workflow.manifest.name --call --input_fasta <path/to/fasta/directory/> --outdir <path/to/output/directory/> --threads <threads>
"""

ANNOTATE_DESCRIPTION = """
Expand All @@ -303,7 +303,7 @@ Usage:
Example:
Call and Annotate genes using input fastas and KOFAM database. Distill using carbon topic and AG ecosystem:
nextflow run $workflow.manifest.name --input_fasta_dir <path/to/fasta/directory/> --outdir <path/to/output/directory/> --call --annotate --distill_topic carbon --distill_ecosystem ag --threads <threads> --use_kofam
nextflow run $workflow.manifest.name --input_fasta <path/to/fasta/directory/> --outdir <path/to/output/directory/> --call --annotate --distill_topic carbon --distill_ecosystem ag --threads <threads> --use_kofam
"""

PRODUCT_DESCRIPTION = """
Expand Down

0 comments on commit 5b8527f

Please sign in to comment.