Skip to content
Snippets Groups Projects
Commit 1115a866 authored by Venkat Malladi's avatar Venkat Malladi
Browse files

Add in options for chrM and tn5 shift.

parent f7e5053d
Branches
Tags
No related merge requests found
......@@ -108,6 +108,34 @@ workflow_parameters:
read length, and then starts another round of reading from the opposite
end of the fragment.
- id: chrM
type: select
required: true
choices:
- [ 'true', 'True']
- [ 'false', 'False']
description: |
In ATAC-seq and DNase-seq, mitochondrial reads are overrepresented.
We recomend filtering these reads out for further downstream analysis.
- id: tn5
type: select
required: true
choices:
- [ 'true', 'True']
- [ 'false', 'False']
description: |
ATAC-seq leverages the hyperactive Tn5 transposase,
preloaded with sequencing adaptors, to simultaneously
fragment transposase-accessible DNA and tag the
fragmented DNA with the sequencing adaptors, a
process called tagmentation. The Tn5 transposase has been shown to function as a
dimer and inserts the two sequencing adaptors into
target regions separated by 9 bp. For downstream
analysis, such as peak-calling and footprint analysis,
coordinates of all read alignments in the filtered
BAM file thus need to be shifted.
- id: design
type: file
required: true
......
......@@ -6,6 +6,8 @@
// Define Input variables
params.reads = "$baseDir/../test_data/*.fastq.gz"
params.pairedEnd = false
params.chrM = true
params.tn5 = true
params.designFile = "$baseDir/../test_data/design_ENCSR265ZXX_SE.txt"
params.genome = 'GRCm38'
params.genomes = []
......@@ -32,6 +34,8 @@ readsList = Channel
// Define regular variables
pairedEnd = params.pairedEnd
chrM = params.chrM
tn5 = params.tn5
designFile = params.designFile
genomeSize = params.genomeSize
chromSizes = params.chromSizes
......@@ -218,14 +222,48 @@ process convertReads {
script:
if (pairedEnd) {
"""
python3 $baseDir/scripts/convert_reads.py -b $deduped -p
"""
if (tn5 && chrM){
"""
python3 $baseDir/scripts/convert_reads.py -b $deduped -p -m -t
"""
}
else if (tn5){
"""
python3 $baseDir/scripts/convert_reads.py -b $deduped -p -t
"""
}
else if (chrM){
"""
python3 $baseDir/scripts/convert_reads.py -b $deduped -p -m
"""
}
else{
"""
python3 $baseDir/scripts/convert_reads.py -b $deduped -p
"""
}
}
else {
"""
python3 $baseDir/scripts/convert_reads.py -b $deduped
"""
if (tn5 && chrM){
"""
python3 $baseDir/scripts/convert_reads.py -b $deduped -m -t
"""
}
else if (tn5){
"""
python3 $baseDir/scripts/convert_reads.py -b $deduped -t
"""
}
else if (chrM){
"""
python3 $baseDir/scripts/convert_reads.py -b $deduped -m
"""
}
else{
"""
python3 $baseDir/scripts/convert_reads.py -b $deduped
"""
}
}
}
......
......@@ -45,10 +45,10 @@ def get_args():
default=True,
action='store_true')
parser.add_argument('-t', '--tn5'
help='Enable TN5 shifting for ATAC-Seq.'
default=True,
action='store_true')
parser.add_argument('-t', '--tn5'
help='Enable TN5 shifting for ATAC-Seq.'
default=True,
action='store_true')
args = parser.parse_args()
return args
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment