Commit c4d7e3d8 authored by Peter van 't Hof's avatar Peter van 't Hof
Browse files

Merge remote-tracking branch 'remotes/origin/fix-278' into feature-skip_abort

parents e04af32c 89427d58
......@@ -28,10 +28,7 @@ upacPatern = re.compile(r'[RYKMSWBDHV]')
if __name__ == "__main__":
for line in sys.stdin:
l = line.strip().split("\t")
if l[3] == "0":
# no alignment to this position
print("\t".join(map(str, l)))
continue
if len(l) >= 3:
l[2] = upacPatern.sub("N", l[2])
l[2] = upacPatern.sub("N", l[2])
print("\t".join(map(str, l)))
......@@ -33,7 +33,9 @@ if __name__ == "__main__":
"""
for line in sys.stdin:
l = line.strip().split("\t")
if l[3] == "0":
l[2] = upacPatern.sub("N", l[2])
if len(l) < 4 or l[3] == "0":
# no alignment to this position
print("\t".join(map(str, l)))
continue
......@@ -49,5 +51,4 @@ if __name__ == "__main__":
if new_size == 0:
l[5] = ""
l[2] = upacPatern.sub("N", l[2])
print("\t".join(map(str, l)))
......@@ -37,6 +37,7 @@ class SamtoolsMpileup(val root: Configurable) extends Samtools with Reference {
var disableBaq: Boolean = config("disable_baq", default = false)
var u: Boolean = config("u", default = false)
var v: Boolean = config("u", default = false)
var minMapQuality: Option[Int] = config("min_map_quality")
var minBaseQuality: Option[Int] = config("min_base_quality")
var depth: Option[Int] = config("depth")
......@@ -57,6 +58,7 @@ class SamtoolsMpileup(val root: Configurable) extends Samtools with Reference {
conditional(outputMappingQuality, "-s") +
conditional(disableBaq, "-B") +
conditional(u, "-u") +
conditional(v, "-v") +
(if (outputAsStsout) "" else required("-o", output)) +
(if (inputAsStdin) "-" else repeat(input))
}
......
......@@ -14,6 +14,7 @@ class Bcftools(val root: Configurable) extends Variantcaller {
val mp = new SamtoolsMpileup(this)
mp.input = inputBams.values.toList
mp.u = true
mp.v = true
mp.reference = referenceFasta()
val bt = new BcftoolsCall(this)
......
......@@ -15,6 +15,7 @@ class BcftoolsSingleSample(val root: Configurable) extends Variantcaller {
val mp = new SamtoolsMpileup(this)
mp.input :+= inputBam
mp.u = true
mp.v = true
mp.reference = referenceFasta()
val bt = new BcftoolsCall(this)
......
Supports Markdown
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