Skip to content
Snippets Groups Projects
Commit 480ff867 authored by Wai Yi Leung's avatar Wai Yi Leung
Browse files

Merge branch 'patch-varscan' into 'develop'

Patch varscan

This pull request fixes an error caused by incorrect passing of the Java flags to the VarScan command used in Gentrap. For local runs, it has no effect. However, these are important for cluster runs.

See merge request !137
parents af445339 f4d7e851
No related branches found
No related tags found
No related merge requests found
......@@ -63,20 +63,27 @@ class CustomVarScan(val root: Configurable) extends BiopetCommandLineFunction {
override def cmdLine: String = required(executable) + required("-vP") + required("""\t\t""")
}
private def varscan = new Mpileup2cns(wrapper.root) {
private val varscan = new Mpileup2cns(wrapper.root) {
strandFilter = Option(0)
outputVcf = Option(1)
}
private def compress = new Bgzip(wrapper.root) {
this.output = wrapper.output
}
private val compress = new Bgzip(wrapper.root)
private def index = new Tabix(wrapper.root) {
private val index = new Tabix(wrapper.root) {
input = compress.output
p = Option("vcf")
}
override def freezeFieldValues(): Unit = {
varscan.output = Option(new File(wrapper.output.toString.stripSuffix(".gz")))
compress.input = List(varscan.output.get)
compress.output = this.output
super.freezeFieldValues()
varscan.qSettings = this.qSettings
varscan.freezeFieldValues()
}
override def beforeGraph: Unit = {
require(output.toString.endsWith(".gz"), "Output must have a .gz file extension")
}
......@@ -85,6 +92,6 @@ class CustomVarScan(val root: Configurable) extends BiopetCommandLineFunction {
// FIXME: manual trigger of commandLine for version retrieval
mpileup.commandLine
mpileup.cmdPipe + " | " + fixMpileup.commandLine + " | " + removeEmptyPile.commandLine + " | " +
varscan.commandLine + " | " + compress.commandLine + " && " + index.commandLine
varscan.commandLine + " && " + compress.commandLine + " && " + index.commandLine
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment