-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathnextflow.config
152 lines (133 loc) · 3.5 KB
/
nextflow.config
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
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
params {
//REQUIRED INPUT PARAMETERS
input_imputed_glob = false
//OR:
plinkfiles = false
//phenofile or fam file must be given, both is also okay
fam = false
//OR
phenofile = false
//OPTIONAL PARAMETERS
trait = "binary"
build = "37"
collection_name = "collection_name"
split_PAR = true
//COVAR PARAMETERS
pca_dims = 10
//tauInit="1,0"
more_covars = "."
more_covars_cols = false//""
cat_covars = false
//OUTPUT PARAMETERS
output = "output/assoc"
//MODULES
//PLINK PRUNING
pruning_parameter = "50 5 0.2"
pruning_maf = 0.05
//BCFTOOLS FILTER
null_filter = "R2>0.8" //FOR PRUNING
additional_bcftools_arg = false //FOR ALL ASSOC
//REGENIE
autochroms = 22
disable_regenie = false
additional_regenie_parameter = ""
regenie_step1_input = false
regenie_bsize = 1000
test = "firth"
pthresh="0.01"
plot_regenie=false
//PLINK ASSOC
plink_assoc = false
plink2_glm_options = false
//SAIGE
saige = false
saige_test_rare = false //NOT TESTED!
//UNUSED
plaintext_email = false
logo = "${baseDir}/assets/ikmblogo.png"
email = null
help = false
maxMultiqcEmailFileSize = 25.MB
//run_name = false //set in regenie.nf
//NOTUSED YET:
remove_missing_phenotypes = false
}
manifest {
name = "ikmb/phewas-assoc"
mainScript = 'regenie.nf'
version = "0.3"
description = "IKMB PheWAS Association Testing Pipeline"
author = "Eike Matthias Wacker, Malte Rühlemann, Lars Wienbrandt & David Ellinghaus"
homePage = "https://github.com/ikmb/gwas-regenie"
nextflowVersion = ">=21.10.0"
}
process.shell = ['/bin/bash', '-euo', 'pipefail']
timeline {
enabled = true
file = "${params.output}/pipeline_info/pipeline_timeline.html"
overwrite = true
}
report {
enabled = true
file = "${params.output}/pipeline_info/pipeline_report.html"
overwrite = true
}
trace {
enabled = true
file = "${params.output}/pipeline_info/pipeline_trace.txt"
overwrite = true
}
dag {
enabled = true
file = "${params.output}/pipeline_info/pipeline_dag.svg"
overwrite = true
}
profiles {
standard {
includeConfig 'conf/base.config'
includeConfig 'conf/medcluster.config'
includeConfig 'conf/resources.config'
}
local {
includeConfig 'conf/base.config'
includeConfig 'conf/local.config'
includeConfig 'conf/resources.config'
}
biomedinf {
includeConfig 'conf/base.config'
includeConfig 'conf/biomedinf.config'
includeConfig 'conf/resources.config'
}
}
// Function to ensure that resource requirements don't go beyond
// a maximum limit
def check_max(obj, type) {
if(type == 'memory'){
try {
if(obj.compareTo(params.max_memory as nextflow.util.MemoryUnit) == 1)
return params.max_memory as nextflow.util.MemoryUnit
else
return obj
} catch (all) {
println " ### ERROR ### Max memory '${params.max_memory}' is not valid! Using default value: $obj"
return obj
}
} else if(type == 'time'){
try {
if(obj.compareTo(params.max_time as nextflow.util.Duration) == 1)
return params.max_time as nextflow.util.Duration
else
return obj
} catch (all) {
println " ### ERROR ### Max time '${params.max_time}' is not valid! Using default value: $obj"
return obj
}
} else if(type == 'cpus'){
try {
return Math.min( obj, params.max_cpus as int )
} catch (all) {
println " ### ERROR ### Max cpus '${params.max_cpus}' is not valid! Using default value: $obj"
return obj
}
}
}