-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
esteinig
committed
Jul 19, 2019
1 parent
04b588b
commit e73b0d0
Showing
17 changed files
with
108,238 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,94 @@ | ||
#!/usr/bin/env nextflow | ||
|
||
/* | ||
* | ||
* Pipeline ARDaP - CARD support pipeline | ||
* Version 1.4 | ||
* Description Download and index CARD DB | ||
* Notes This is a support script for updating indices | ||
* of the CARD DB for ARDaP. | ||
* | ||
*/ | ||
|
||
|
||
//Overwrites data in resources/card/latest, can be changed here or on CLI: | ||
|
||
params.outdir = "$baseDir/resources/card/latest" | ||
params.window = 10000 | ||
|
||
process Download { | ||
|
||
executor 'local' | ||
publishDir "${params.outdir}", pattern: "*.txt", mode: "copy" | ||
publishDir "${params.outdir}", pattern: "card.fasta", mode: "copy" | ||
|
||
|
||
output: | ||
file('date.txt') | ||
file("card.fasta") into (card_bwa, card_sam, card_bed) | ||
|
||
shell: | ||
|
||
""" | ||
wget https://card.mcmaster.ca/latest/data -O card-data.tar.bz2 | ||
tar xvjf card-data.tar.bz2 | ||
wget https://card.mcmaster.ca/latest/ontology -O card-ontology.tar.bz2 | ||
tar xvjf card-ontology.tar.bz2 | ||
mv nucleotide_fasta_protein_homolog_model.fasta card.fasta | ||
date > date.txt | ||
""" | ||
|
||
} | ||
|
||
process BWAIndex { | ||
|
||
label "index" | ||
publishDir "${params.outdir}", mode: "copy" | ||
|
||
input: | ||
file(ref) from card_bwa | ||
|
||
output: | ||
file("card.*") | ||
|
||
""" | ||
bwa index -a is $ref | ||
""" | ||
|
||
} | ||
|
||
process SAMtoolsIndex { | ||
|
||
label "index" | ||
publishDir "${params.outdir}", mode: "copy" | ||
|
||
input: | ||
file(ref) from card_sam | ||
|
||
output: | ||
file("${ref}.fai") into card_bed_fai | ||
|
||
""" | ||
samtools faidx $ref | ||
""" | ||
|
||
} | ||
|
||
process BEDtoolsIndex { | ||
|
||
label "card" | ||
publishDir "${params.outdir}", mode: "copy" | ||
|
||
input: | ||
file(ref) from card_bed | ||
file(ref_index) from card_bed_fai | ||
|
||
output: | ||
file("${ref.baseName}.bed") | ||
file("${ref.baseName}.coverage.bed") | ||
|
||
""" | ||
bedtools makewindows -g $ref_index -w $params.window > ${ref.baseName}.bed && bedtools makewindows -g $ref_index -w 90000000 > ${ref.baseName}.coverage.bed | ||
""" | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
params { | ||
|
||
CLUSTER_SNP = 3 | ||
CLUSTER_WINDOW_SNP = 10 | ||
MLEAF_SNP = 0.95 | ||
QD_SNP = 10.0 | ||
MQ_SNP = 30.0 | ||
FS_SNP = 60.0 | ||
QUAL_SNP = 30.0 | ||
LOW_DEPTH = 2 | ||
HIGH_DEPTH = 3 | ||
|
||
MLEAF_INDEL = 0.95 | ||
QD_INDEL = 10.0 | ||
MQ_INDEL = 30.0 | ||
FS_INDEL = 200.0 | ||
QUAL_INDEL = 30.0 | ||
LOW_DEPTH_INDEL = 2 | ||
HIGH_DEPTH_INDEL = 3 | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,73 @@ | ||
params { | ||
|
||
fastq = "test/*_{1,2}.fastq.gz" | ||
reference = "test/K96243.fasta" | ||
gwas = true | ||
matrix = true | ||
annotate = true | ||
mixtures = true | ||
phylogeny = false | ||
antibiotic_res = true | ||
strain = "all" | ||
tech = "Illumina" | ||
pairing = "PE" | ||
window = 10000 | ||
indel_merge = true | ||
tri_tetra_allelic = false | ||
size = 6000000 | ||
snpeff = "Burkholderia_pseudomallei_k96243" | ||
phred = "-phred33" | ||
org = "haploid" | ||
} | ||
|
||
includeConfig 'configs/gatk.config' | ||
|
||
process { | ||
|
||
errorStrategy = "ignore" | ||
|
||
conda = "/home/esteinig/miniconda3/envs/ardap" | ||
|
||
withLabel: card { | ||
cpus = 1 | ||
memory = "4G" | ||
time = "2h" | ||
} | ||
|
||
withLabel: index { | ||
cpus = 1 | ||
memory = "4G" | ||
time = "2h" | ||
} | ||
|
||
withLabel: spandx_default { | ||
cpus = 2 | ||
memory = "4G" | ||
time = "2h" | ||
} | ||
|
||
withLabel: spandx_alignment { | ||
cpus = 8 | ||
memory = "8G" | ||
time = "2h" | ||
} | ||
|
||
withLabel: spandx_gatk { | ||
cpus = 8 | ||
memory = "8G" | ||
time = "2h" | ||
} | ||
|
||
withLabel: spandx_snpeff { | ||
cpus = 4 | ||
memory = "4G" | ||
time = "2h" | ||
} | ||
|
||
withLabel: spandx_pindel { | ||
cpus = 8 | ||
memory = "8G" | ||
time = "2h" | ||
} | ||
|
||
} |
Binary file added
BIN
+2.2 MB
resources/snpeff/Burkholderia_pseudomallei_k96243/snpEffectPredictor.bin
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
>PrefixNX/1 | ||
AGATGTGTATAAGAGACAG | ||
>PrefixNX/2 | ||
AGATGTGTATAAGAGACAG | ||
>Trans1 | ||
TCGTCGGCAGCGTCAGATGTGTATAAGAGACAG | ||
>Trans1_rc | ||
CTGTCTCTTATACACATCTGACGCTGCCGACGA | ||
>Trans2 | ||
GTCTCGTGGGCTCGGAGATGTGTATAAGAGACAG | ||
>Trans2_rc | ||
CTGTCTCTTATACACATCTCCGAGCCCACGAGAC | ||
>PrefixPE/1 | ||
AATGATACGGCGACCACCGAGATCTACACTCTTTCCCTACACGACGCTCTTCCGATCT | ||
>PrefixPE/2 | ||
CAAGCAGAAGACGGCATACGAGATCGGTCTCGGCATTCCTGCTGAACCGCTCTTCCGATCT | ||
>PCR_Primer1 | ||
AATGATACGGCGACCACCGAGATCTACACTCTTTCCCTACACGACGCTCTTCCGATCT | ||
>PCR_Primer1_rc | ||
AGATCGGAAGAGCGTCGTGTAGGGAAAGAGTGTAGATCTCGGTGGTCGCCGTATCATT | ||
>PCR_Primer2 | ||
CAAGCAGAAGACGGCATACGAGATCGGTCTCGGCATTCCTGCTGAACCGCTCTTCCGATCT | ||
>PCR_Primer2_rc | ||
AGATCGGAAGAGCGGTTCAGCAGGAATGCCGAGACCGATCTCGTATGCCGTCTTCTGCTTG | ||
>FlowCell1 | ||
TTTTTTTTTTAATGATACGGCGACCACCGAGATCTACAC | ||
>FlowCell2 | ||
TTTTTTTTTTCAAGCAGAAGACGGCATACGA | ||
>TruSeq2_SE | ||
AGATCGGAAGAGCTCGTATGCCGTCTTCTGCTTG | ||
>TruSeq2_PE_f | ||
AGATCGGAAGAGCGTCGTGTAGGGAAAGAGTGT | ||
>TruSeq2_PE_r | ||
AGATCGGAAGAGCGGTTCAGCAGGAATGCCGAG | ||
>PrefixPE/1 | ||
TACACTCTTTCCCTACACGACGCTCTTCCGATCT | ||
>PrefixPE/2 | ||
GTGACTGGAGTTCAGACGTGTGCTCTTCCGATCT | ||
>PE1 | ||
TACACTCTTTCCCTACACGACGCTCTTCCGATCT | ||
>PE1_rc | ||
AGATCGGAAGAGCGTCGTGTAGGGAAAGAGTGTA | ||
>PE2 | ||
GTGACTGGAGTTCAGACGTGTGCTCTTCCGATCT | ||
>PE2_rc | ||
AGATCGGAAGAGCACACGTCTGAACTCCAGTCAC | ||
>PrefixPE/1 | ||
TACACTCTTTCCCTACACGACGCTCTTCCGATCT | ||
>PrefixPE/2 | ||
GTGACTGGAGTTCAGACGTGTGCTCTTCCGATCT | ||
>TruSeq3_IndexedAdapter | ||
AGATCGGAAGAGCACACGTCTGAACTCCAGTCAC | ||
>TruSeq3_UniversalAdapter | ||
AGATCGGAAGAGCGTCGTGTAGGGAAAGAGTGTA |
Oops, something went wrong.