Skip to content

Commit

Permalink
updating the way purge_dups outputs must be dynamically included in t…
Browse files Browse the repository at this point in the history
…he inputs of rule_all
  • Loading branch information
LiaOb21 committed Feb 28, 2024
1 parent 3f3883f commit 3b41f75
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions workflow/rules/common.smk
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,7 @@ def get_all_inputs():
"results/oatk/oatk.asm.mito.ctg.fasta", # mitochondrion fasta from oatk
"results/hifiasm/hifiasm.asm.p_ctg.gfa", # draft hifiasm assembly.gfa
"results/hifiasm/hifiasm.asm.p_ctg.fa", # draft hifiasm assembly.fa
"results/purge_dups/hifiasm_p_purged.fa", # purged assembly with purge_dups
"results/purge_dups_alt/hifiasm_a_purged.fa", # purged alternate assembly with purge_dups2
# "results/ncbi_fcsgx/hifiasm.asm.p_ctg_clean.fa", # to add if eventually I manage to integrate fcsgx
expand("results/fastp/{sample}_report_fastp.HiC.html", sample=samples), # fastp report for HiC reads pre-processing
[f"results/purge_dups/hifiasm_p_purged.fa.{ext}" for ext in ["sa", "amb", "ann", "bwt", "pac"]] if config["include_purge_dups"] else [f"results/hifiasm/hifiasm.asm.p_ctg.fa.{ext}" for ext in ["sa", "amb", "ann", "bwt", "pac"]], # bwa index outputs
expand("results/arima_mapping_pipeline/RAW_DIR/{sample}_1.bam", sample=samples), # bwa mem bam file1
Expand All @@ -27,6 +26,9 @@ def get_all_inputs():
]
if config["oatk"]["optional_params"]["-p"]:
inputs.append("results/oatk/oatk.asm.pltd.ctg.fasta") # chloroplast fasta from oatk
if config["include_purge_dups"] == True:
inputs.append("results/purge_dups/hifiasm_p_purged.fa") # purged assembly with purge_dups
inputs.append("results/purge_dups_alt/hifiasm_a_purged.fa") # # purged alternate assembly with purge_dups2
return inputs


Expand Down

0 comments on commit 3b41f75

Please sign in to comment.