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

Converted fastqc to new summary

parent b87a4b04
......@@ -141,7 +141,11 @@ class Fastqc(root: Configurable) extends nl.lumc.sasc.biopet.extensions.Fastqc(r
} else Set()
}
/** Summary of the FastQC run, stored in a [[Json]] object */
/**
* Summary of the FastQC run, stored in a [[Json]] object
*
* @deprecated
*/
def summary: Json = {
val outputMap =
......@@ -163,9 +167,21 @@ class Fastqc(root: Configurable) extends nl.lumc.sasc.biopet.extensions.Fastqc(r
ConfigUtils.mapToJson(outputMap)
}
def summaryFiles: Map[String, File] = Map("test" -> this.fastqfile)
def summaryFiles: Map[String, File] = {
Map("plot_duplication_levels" -> ("Images" + File.separator + "duplication_levels.png"),
"plot_kmer_profiles" -> ("Images" + File.separator + "kmer_profiles.png"),
"plot_per_base_gc_content" -> ("Images" + File.separator + "per_base_gc_content.png"),
"plot_per_base_n_content" -> ("Images" + File.separator + "per_base_n_content.png"),
"plot_per_base_quality" -> ("Images" + File.separator + "per_base_quality.png"),
"plot_per_base_sequence_content" -> ("Images" + File.separator + "per_base_sequence_content.png"),
"plot_per_sequence_gc_content" -> ("Images" + File.separator + "per_sequence_gc_content.png"),
"plot_per_sequence_quality" -> ("Images" + File.separator + "per_sequence_quality.png"),
"plot_sequence_length_distribution" -> ("Images" + File.separator + "sequence_length_distribution.png"),
"fastqc_data" -> ("fastqc_data.txt"))
.map(x => (x._1 -> new File(outputDir, x._2))) ++ Map("fastq_file" -> this.fastqfile)
}
def summaryData: Map[String, Any] = Map()
def summaryData: Map[String, Any] = Map("version" -> getVersion)
}
object Fastqc {
......
......@@ -86,7 +86,7 @@ class Flexiprep(val root: Configurable) extends QScript with SummaryQScript with
case _ =>
}
summary.out = new File(outputDir, sampleId.getOrElse("x") + "-" + libId.getOrElse("x") + ".qc.summary.json")
//summary.out = new File(outputDir, sampleId.getOrElse("x") + "-" + libId.getOrElse("x") + ".qc.summary.json")
}
def biopetScript() {
......@@ -106,22 +106,24 @@ class Flexiprep(val root: Configurable) extends QScript with SummaryQScript with
fastqc_R1 = Fastqc(this, input_R1, new File(outputDir, R1_name + ".fastqc/"))
add(fastqc_R1)
summary.addFastqc(fastqc_R1)
//summary.addFastqc(fastqc_R1)
addSummarizable(fastqc_R1, "fastqc_R1")
outputFiles += ("fastqc_R1" -> fastqc_R1.output)
val md5sum_R1 = Md5sum(this, input_R1, outputDir)
add(md5sum_R1)
summary.addMd5sum(md5sum_R1, R2 = false, after = false)
//val md5sum_R1 = Md5sum(this, input_R1, outputDir)
//add(md5sum_R1)
//summary.addMd5sum(md5sum_R1, R2 = false, after = false)
if (paired) {
fastqc_R2 = Fastqc(this, input_R2.get, new File(outputDir, R2_name + ".fastqc/"))
add(fastqc_R2)
summary.addFastqc(fastqc_R2, R2 = true)
addSummarizable(fastqc_R2, "fastqc_R2")
//summary.addFastqc(fastqc_R2, R2 = true)
outputFiles += ("fastqc_R2" -> fastqc_R2.output)
val md5sum_R2 = Md5sum(this, input_R2.get, outputDir)
add(md5sum_R2)
summary.addMd5sum(md5sum_R2, R2 = true, after = false)
//val md5sum_R2 = Md5sum(this, input_R2.get, outputDir)
//add(md5sum_R2)
//summary.addMd5sum(md5sum_R2, R2 = true, after = false)
}
}
......@@ -263,13 +265,14 @@ class Flexiprep(val root: Configurable) extends QScript with SummaryQScript with
summary.addMd5sum(md5sum_R2, R2 = true, after = true)
}
fastqc_R1_after = Fastqc(this, R1, new File(outputDir, R1_name + ".qc.fastqc/"))
addSummarizable(fastqc_R1_after, "fastqc_R1_qc")
add(fastqc_R1_after)
summary.addFastqc(fastqc_R1_after, after = true)
addSummarizable(fastqc_R1_after, "fastqc_R1_qc")
//summary.addFastqc(fastqc_R1_after, after = true)
if (paired) {
fastqc_R2_after = Fastqc(this, R2, new File(outputDir, R2_name + ".qc.fastqc/"))
add(fastqc_R2_after)
summary.addFastqc(fastqc_R2_after, R2 = true, after = true)
addSummarizable(fastqc_R2_after, "fastqc_R2_qc")
//summary.addFastqc(fastqc_R2_after, R2 = true, after = true)
}
}
......
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