diff --git a/seqnado/workflow/snakefile_consensus_peaks b/seqnado/workflow/snakefile_consensus_peaks deleted file mode 100644 index 61f752e0..00000000 --- a/seqnado/workflow/snakefile_consensus_peaks +++ /dev/null @@ -1,42 +0,0 @@ -import os -import sys -import shutil -from datetime import datetime -import glob -from snakemake.utils import min_version -import seqnado.utils -import pandas as pd -import pathlib - -ASSAY = "CONSENUS_PEAKS" -configfile: "config_consensus_peaks.yml" -container: "library://asmith151/seqnado/seqnado_pipeline:latest" - - -seqnado.utils.format_config_dict(config) - - -# Get experiment design -# Require a fn column and a group column -design_path = pathlib.Path(config["design"]) -if design_path.exists(): - DESIGN = pd.read_csv(design_path, sep="[\s+,\t]", engine="python") - assert DESIGN.shape[0] > 0, "No samples found in design file" - -else: - raise ValueError("No design file found") - - -SAMPLE_NAMES = [pathlib.Path(fn).stem for fn in DESIGN.fn] -GROUPS = DESIGN.group.unique().tolist() - - -include: "rules/alignment_post_processing.smk" -include: "rules/peak_call.smk" -include: "rules/pileup.smk" -include: "rules/consensus_peaks.smk" - - -rule all: - input: - peaks=expand("seqnado_output/consensus_peaks/{group}.bed", group=GROUPS), diff --git a/seqnado/workflow/snakefile_rna b/seqnado/workflow/snakefile_rna index 6cafa0c3..e81f5f6a 100644 --- a/seqnado/workflow/snakefile_rna +++ b/seqnado/workflow/snakefile_rna @@ -59,7 +59,7 @@ include: "rules/heatmap.smk" # Define output files ANALYSIS_OUTPUT = utils.define_output_files( - sample_names=SAMPLE_NAMES, assay=ASSAY, can_run_deseq2=CAN_RUN_DESEQ2, project_name=PROJECT_NAME, **config + snakemake_design=DESIGN, sample_names=SAMPLE_NAMES, assay=ASSAY, can_run_deseq2=CAN_RUN_DESEQ2, project_name=PROJECT_NAME, **config ) rule all: diff --git a/seqnado/workflow/snakefile_snp b/seqnado/workflow/snakefile_snp index 16a26bfd..220ff7be 100755 --- a/seqnado/workflow/snakefile_snp +++ b/seqnado/workflow/snakefile_snp @@ -41,7 +41,8 @@ include: "rules/hub.smk" include: "rules/qc.smk" include: "rules/variant.smk" -ANALYSIS_OUTPUT = utils.define_output_files(sample_names=SAMPLE_NAMES, +ANALYSIS_OUTPUT = utils.define_output_files(snakemake_design=DESIGN, + sample_names=SAMPLE_NAMES, assay=ASSAY, **config) @@ -69,4 +70,4 @@ onerror: shutil.copyfile(log, log_out) print( f"An error occurred. Please check the log file {log_out} for more information." - ) \ No newline at end of file + )