-
Notifications
You must be signed in to change notification settings - Fork 0
/
Snakefile
49 lines (39 loc) · 1.65 KB
/
Snakefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
from snakemake.utils import min_version
import math
min_version("7.25")
# This is the main Snakefile for the workflow. It compiles the output files
# required by the workflow. The rules used to produce the outputs are found
# in the included .smk files below:
include: "rules/0.0_angsd_pipeline.smk"
include: "rules/1.0_landscape_modeling.smk"
include: "rules/2.0_downsampling.smk"
include: "rules/3.0_bcftools_roh.smk"
all_outputs = []
all_outputs.extend(
[
"results/datasets/{dataset}/analyses/landscape_models/{dataset}.{ref}_all_{sites}-filts_heterozygosity-landuse.tsv",
"results/datasets/{dataset}/analyses/landscape_models/{dataset}.{ref}_all_{sites}-filts_fst-landuse.tsv",
"results/datasets/{dataset}/analyses/roh/bcftools/{dataset}.{ref}_all_{sites}-filts.regs.GLonly.roh",
"results/datasets/{dataset}/analyses/roh/bcftools/{dataset}.{ref}_all_{sites}-filts.regs.calls.roh",
]
)
if config["downsample"]["fst"]:
all_outputs.append(
"results/datasets/{dataset}/analyses/fst/downsampled/{dataset}.{ref}_poppairs.downsampled_{sites}-filts.fst.global.tsv"
)
if config["downsample"]["thetas"]:
all_outputs.append(
"results/datasets/{dataset}/analyses/thetas/downsampled/{dataset}.{ref}_all.downsampled_{sites}-filts.thetaMean.{win}_{step}.tsv"
)
rule all:
input:
rules.angsd_all.input,
expand(
all_outputs,
dataset=config["dataset"],
ref=config["reference"]["name"],
sites="allsites",
win=config["params"]["thetas"]["win_size"],
step=config["params"]["thetas"]["win_step"],
),
default_target: True