-
Notifications
You must be signed in to change notification settings - Fork 0
/
Snakefile
39 lines (31 loc) · 1.14 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
## split out our samples into local and downloaded
local_samples, SRA_samples = [], {}
with open(config['samples'],'r') as fin:
for line in fin:
name, ID, *_ = line.split()
if ID == 'local':
local_samples.append(name)
elif name[0] == '#':
continue
else:
SRA_samples[name] = ID
samples = local_samples + list(SRA_samples.keys())
workflow._singularity_args = f'-B $TMPDIR'
include: 'snakepit/public_downloading.smk'
include: 'snakepit/pangenome_construction.smk'
include: 'snakepit/pangenome_analysis.smk'
include: 'snakepit/pangenome_alignment.smk'
include: 'snakepit/PCA.smk'
def make_targets():
targets = []
for graph, config_items in config['graphs'].items():
for reference in config['references'].keys():
targets.append(f'{graph}/node_coverage.{reference}.csv.gz')
targets.append(f'sample_information.{reference}.csv')
targets.append(f'PCA/control.eigenvec')
for graph, config_items in config['gggenes'].items():
targets.append(f'gggenes/{graph}.repeats.tsv')
return targets
rule all:
input:
make_targets()