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

Added bedtools sorted flag as default

parent bffd796d
...@@ -41,6 +41,8 @@ class BamMetrics(val root: Configurable) extends QScript ...@@ -41,6 +41,8 @@ class BamMetrics(val root: Configurable) extends QScript
@Input(doc = "Bam File", shortName = "BAM", required = true) @Input(doc = "Bam File", shortName = "BAM", required = true)
var inputBam: File = _ var inputBam: File = _
override def defaults = Map("bedtoolscoverage" -> Map("sorted" -> true))
/** return location of summary file */ /** return location of summary file */
def summaryFile = (sampleId, libId) match { def summaryFile = (sampleId, libId) match {
case (Some(s), Some(l)) => new File(outputDir, s + "-" + l + ".BamMetrics.summary.json") case (Some(s), Some(l)) => new File(outputDir, s + "-" + l + ".BamMetrics.summary.json")
......
...@@ -41,6 +41,8 @@ class BedtoolsCoverage(val root: Configurable) extends Bedtools { ...@@ -41,6 +41,8 @@ class BedtoolsCoverage(val root: Configurable) extends Bedtools {
@Argument(doc = "diffStrand", required = false) @Argument(doc = "diffStrand", required = false)
var diffStrand: Boolean = false var diffStrand: Boolean = false
var sorted: Boolean = config("sorted", default = false, freeVar = false)
override def defaultCoreMemory = 4.0 override def defaultCoreMemory = 4.0
/** Returns command to execute */ /** Returns command to execute */
...@@ -50,6 +52,7 @@ class BedtoolsCoverage(val root: Configurable) extends Bedtools { ...@@ -50,6 +52,7 @@ class BedtoolsCoverage(val root: Configurable) extends Bedtools {
conditional(depth, "-d") + conditional(depth, "-d") +
conditional(sameStrand, "-s") + conditional(sameStrand, "-s") +
conditional(diffStrand, "-S") + conditional(diffStrand, "-S") +
conditional(sorted, "-sorted") +
(if (outputAsStsout) "" else " > " + required(output)) (if (outputAsStsout) "" else " > " + required(output))
} }
......
Markdown is supported
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