-
Notifications
You must be signed in to change notification settings - Fork 0
/
main.nf
executable file
·88 lines (53 loc) · 2.5 KB
/
main.nf
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
/*
=================================================================================================
Title : Nextflow workflow on variant analysis
=================================================================================================
Author : Dr. Majeed Jamakhani
=================================================================================================
*/
/*
=================================================================================================
Input Directories
=================================================================================================
*/
params.reads = "s3://mj-nextflow-aws-bucket/data/ggal/*_{1,2}.fq"
params.genome = "s3://mj-nextflow-aws-bucket/genome/transcriptome.fa"
/*
=================================================================================================
Ouput Directories
=================================================================================================
*/
params.trimmed = "s3://mj-nextflow-aws-bucket/results/trimmed"
params.multiqc = "s3://mj-nextflow-aws-bucket/results/multiqc"
params.outdir = "s3://mj-nextflow-aws-bucket/results"
params.qcdir = "s3://mj-nextflow-aws-bucket/results/QC"
/*
=================================================================================================
Channels
=================================================================================================
*/
read_pairs_ch = Channel.fromFilePairs(params.reads, checkIfExists: true)
read_pairs_ch2 = Channel.fromFilePairs(params.reads, checkIfExists: true)
genome_ch = Channel.fromPath(params.genome, checkIfExists: true)
/*
=================================================================================================
Include Modules
=================================================================================================
*/
include {BEFOREQC} from "./modules/beforeqc"
include {SICKLE} from "./modules/sickle"
include {AFTERQC} from "./modules/afterqc"
include {MULTIQC} from "./modules/multiqc"
include {BWAINDEX} from "./modules/bwa_index"
/*
=================================================================================================
Workflow
=================================================================================================
*/
workflow {
beforeqc_ch = BEFOREQC (read_pairs_ch)
trimmed_ch = SICKLE (read_pairs_ch)
afterqc_ch = AFTERQC (trimmed_ch)
bwa_index_ch = BWAINDEX (genome_ch)
MULTIQC(beforeqc_ch.mix(afterqc_ch).collect())
}