-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathSnakefile
130 lines (118 loc) · 4.61 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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
#!/bin/env python
#### configuration file ####
configfile: "config/config.yaml"
include: "workflow/rules/common.smk"
wildcard_constraints:
regions='|'.join([r for r in (config["regions"] + config["regions_mut"])]),
samples='|'.join([s for s in (
config["xr"]["samples"] +
config["ds"]["samples"] +
config["edu"]["samples"] +
config["okseq"]["samples"] +
config["mutation"]["samples"]
)]),
tss_tes='tss|tes'
rule all:
input:
lambda w: allInput(
sampleList=config["edu"]["samples"],
srrEnabled=config["edu"]["srr"]["enabled"],
srrList=config["edu"]["srr"]["codes"],
method="edu"
),
lambda w: allInput(
sampleList=config["okseq"]["samples"],
srrEnabled=config["okseq"]["srr"]["enabled"],
srrList=config["okseq"]["srr"]["codes"],
method="okseq"
),
lambda w: allInput(
sampleList=config["mutation"]["samples"],
method="mutation",
regions=config["regions_mut"]
),
lambda w: allInput(
sampleList=config["ds"]["samples"],
method="ds",
regions=config["regions"]
),
lambda w: allInput(
sampleList=config["xr"]["samples"],
method="xr",
regions=config["regions"]
),
lambda w: allInput(
method="report",
regions=config["regions"]
),
# Prepare genome
include: "workflow/rules/unzipTSS.smk"
include: "workflow/rules/genome_download.smk"
include: "workflow/rules/genome_build.smk"
include: "workflow/rules/genome_indexing.smk"
# EdU Analysis
if config["edu"]["srr"]["enabled"]:
include: "workflow/rules/sra_edu.smk"
include: "workflow/rules/fastqc.smk"
include: "workflow/rules/align.smk"
include: "workflow/rules/bam2bed.smk"
include: "workflow/rules/sort_filter.smk"
include: "workflow/rules/sep_strands.smk"
include: "workflow/rules/genomecov.smk"
include: "workflow/rules/bedGraphToBigWig.smk"
include: "workflow/rules/bam_correlation.smk"
include: "workflow/rules/replication_timing.smk"
include: "workflow/rules/produceReplicationDomains.smk"
include: "workflow/rules/getPublicRepli.smk"
include: "workflow/rules/bamCompare.smk"
include: "workflow/rules/bdg2bed.smk"
include: "workflow/rules/merge_bdg.smk"
# OK-seq Analysis
if config["okseq"]["srr"]["enabled"]:
include: "workflow/rules/sra_okseq.smk"
#include: "workflow/rules/fastqc.smk" # The rule implemented in EdU Analysis
include: "workflow/rules/adaptor_handling.smk"
#include: "workflow/rules/align.smk" # The rule implemented in EdU Analysis
#include: "workflow/rules/bam_correlation.smk" # The rule implemented in EdU Analysis
include: "workflow/rules/produceInitiationZones.smk"
include: "workflow/rules/okseqIntersect.smk"
include: "workflow/rules/getHeLaIZ.smk"
# Mutation Analysis
include: "workflow/rules/get_sbs_muts.smk"
include: "workflow/rules/organize.smk"
include: "workflow/rules/filter_target_muts.smk"
#include: "workflow/rules/sep_strands.smk" # The rule implemented in EdU Analysis
include: "workflow/rules/intergenic.smk"
# Chromatin States
include: "workflow/rules/getChromHMM.smk"
# Process Retrieved Data
include: "workflow/rules/intersect2repDomains.smk"
include: "workflow/rules/mv_genome.smk"
include: "workflow/rules/make_windows.smk"
include: "workflow/rules/countMotifs.smk"
# Further Analyses
include: "workflow/rules/combine_replicates.smk"
include: "workflow/rules/ts_nts.smk"
include: "workflow/rules/tss.smk"
include: "workflow/rules/pre_mapping.smk"
include: "workflow/rules/mapping2regions.smk"
include: "workflow/rules/combine_files.smk"
# Figures
include: "workflow/rules/figure1.smk"
include: "workflow/rules/figure2.smk"
include: "workflow/rules/figure3_S6_S7.smk"
include: "workflow/rules/figure4B.smk"
include: "workflow/rules/figure4C_4D_S13_S15_S16.smk"
include: "workflow/rules/figure4E_4F_S17toS24.smk"
include: "workflow/rules/figure4G.smk"
include: "workflow/rules/figure5A.smk"
include: "workflow/rules/figure5B_5C_5D.smk"
include: "workflow/rules/bam_corr_graphs.smk" # contains figure S2A
include: "workflow/rules/figureS3B_S3C_S3D.smk"
include: "workflow/rules/figureS4.smk"
include: "workflow/rules/figureS5.smk"
include: "workflow/rules/figureS8.smk"
include: "workflow/rules/figureS9_S10.smk"
include: "workflow/rules/figureS11_S12.smk"
include: "workflow/rules/figureS14.smk"
include: "workflow/rules/figureS25.smk"