This repository was archived by the owner on May 11, 2026. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy path1_make_tables.Snakefile
More file actions
61 lines (47 loc) · 1.63 KB
/
1_make_tables.Snakefile
File metadata and controls
61 lines (47 loc) · 1.63 KB
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
#!/usr/bin/env snakemake
'''
Makes:
1. Top loci table
2. Study table
3. Trait to EFO look up table
4. Finemapping table
5. Input manifest for LD calculation table
'''
from datetime import date
from snakemake.remote.FTP import RemoteProvider as FTPRemoteProvider
from snakemake.remote.GS import RemoteProvider as GSRemoteProvider
from snakemake.remote.HTTP import RemoteProvider as HTTPRemoteProvider
# Load configuration
configfile: "configs/config.yaml"
tmpdir = config['temp_dir']
KEEP_LOCAL = False
if 'version' not in config:
config['version'] = date.today().strftime("%y%m%d")
targets = []
# Make targets for top loci table
targets.append(
'output/{version}/toploci.parquet'.format(version=config['version']) )
# Make targets for study table
targets.append(
'output/{version}/studies.parquet'.format(version=config['version']) )
# Make targets for study table
targets.append(
'output/{version}/trait_efo.parquet'.format(version=config['version']) )
# Make targets for finemapping table
targets.append(
'output/{version}/finemapping.parquet'.format(version=config['version']) )
# Make targets for LD input table
targets.append(
'output/{version}/ld_analysis_input.tsv'.format(version=config['version']) )
# Make trait to EFO lut table
targets.append(
'output/{version}/trait_efo.parquet'.format(version=config['version']) )
# Trigger making of targets
rule all:
input:
targets
log: f"logs/{config['version']}/1_make_tables.log"
# Add workflows
include: 'snakefiles/study_and_top_loci_tables.Snakefile'
include: 'snakefiles/finemapping_table.Snakefile'
include: 'snakefiles/ld_table_1.Snakefile'