Skip to content
Snippets Groups Projects
Commit 2b9fd392 authored by bow's avatar bow
Browse files

Add indexing job to CustomVarScan

parent 6ca9d8be
No related branches found
No related tags found
No related merge requests found
......@@ -24,6 +24,9 @@ class CustomVarScan(val root: Configurable) extends BiopetCommandLineFunction {
@Output(doc = "Output VCF file", required = true)
var output: File = null
@Output(doc = "Output VCF file index", required = true)
lazy val outputIndex: File = new File(output.toString + ".tbi")
// mpileup, varscan, fix_mpileup.py, binom_test.py, bgzip, tabix
private def mpileup = new SamtoolsMpileup(wrapper.root) {
this.input = wrapper.input
......@@ -54,11 +57,16 @@ class CustomVarScan(val root: Configurable) extends BiopetCommandLineFunction {
this.output = wrapper.output
}
private def index = new Tabix(wrapper.root) {
input = compress.output
p = Option("vcf")
}
override def beforeGraph: Unit = {
require(output.toString.endsWith(".gz"), "Output must have a .gz file extension")
}
def cmdLine: String =
mpileup.cmdPipe + " | " + fixMpileup.commandLine + " | " + removeEmptyPile.commandLine + " | " +
varscan.commandLine + " | " + compress.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