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

Merge remote-tracking branch 'origin/master' into develop

Conflicts:
	pom.xml
	protected/biopet-gatk-extensions/pom.xml
	protected/biopet-gatk-pipelines/pom.xml
	protected/biopet-protected-package/pom.xml
	protected/pom.xml
	public/bam2wig/pom.xml
	public/bammetrics/pom.xml
	public/basty/pom.xml
	public/biopet-framework/pom.xml
	public/biopet-public-package/pom.xml
	public/carp/pom.xml
	public/flexiprep/pom.xml
	public/flexiprep/src/main/scala/nl/lumc/sasc/biopet/pipelines/flexiprep/Flexiprep.scala
	public/gentrap/pom.xml
	public/kopisu/pom.xml
	public/mapping/pom.xml
	public/pom.xml
	public/sage/pom.xml
	public/shiva/pom.xml
	public/toucan/pom.xml
	public/yamsvp/pom.xml
parents 5ef02db9 b77d7b4c
......@@ -107,7 +107,8 @@ class Gentrap(val root: Configurable) extends QScript
/** Adds output merge jobs for the given expression mode */
// TODO: can we combine the enum with the file extension (to reduce duplication and potential errors)
private def makeMergeTableJob(inFunc: (Sample => Option[File]), ext: String, idCols: List[Int], valCol: Int,
outBaseName: String = "all_samples", fallback: String = "-"): Option[MergeTables] = {
numHeaderLines: Int = 1, outBaseName: String = "all_samples",
fallback: String = "-"): Option[MergeTables] = {
val tables = samples.values.map { inFunc }.toList.flatten
tables.nonEmpty
.option {
......@@ -118,6 +119,7 @@ class Gentrap(val root: Configurable) extends QScript
job.valueColumnIndex = valCol
job.fileExtension = Option(ext)
job.fallbackString = Option(fallback)
job.numHeaderLines = Option(numHeaderLines)
// TODO: separate the addition into another function?
job
}
......@@ -147,7 +149,8 @@ class Gentrap(val root: Configurable) extends QScript
/** Merged gene fragment count table */
private lazy val geneFragmentsCountJob =
makeMergeTableJob((s: Sample) => s.geneFragmentsCount, ".fragments_per_gene", List(1), 2, fallback = "0")
makeMergeTableJob((s: Sample) => s.geneFragmentsCount, ".fragments_per_gene", List(1), 2, numHeaderLines = 0,
fallback = "0")
/** Heatmap job for gene fragment count */
private lazy val geneFragmentsCountHeatmapJob =
......@@ -155,7 +158,8 @@ class Gentrap(val root: Configurable) extends QScript
/** Merged exon fragment count table */
private lazy val exonFragmentsCountJob =
makeMergeTableJob((s: Sample) => s.exonFragmentsCount, ".fragments_per_exon", List(1), 2, fallback = "0")
makeMergeTableJob((s: Sample) => s.exonFragmentsCount, ".fragments_per_exon", List(1), 2, numHeaderLines = 0,
fallback = "0")
/** Heatmap job for exon fragment count */
private lazy val exonFragmentsCountHeatmapJob =
......
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