ShivaReport.scala 1.79 KB
Newer Older
1
2
package nl.lumc.sasc.biopet.pipelines.shiva

3
import nl.lumc.sasc.biopet.core.report.{ ReportSection, MultisampleReportBuilder, ReportPage }
4
5
6
7
8
9
import nl.lumc.sasc.biopet.pipelines.flexiprep.FlexiprepReport

/**
 * Created by pjvan_thof on 3/30/15.
 */
object ShivaReport extends MultisampleReportBuilder {
10
11
12
  def indexPage = ReportPage(
    Map(
      "General" -> ReportPage(Map(), List(
Peter van 't Hof's avatar
Peter van 't Hof committed
13
        "Variantcalling" -> ReportSection("/nl/lumc/sasc/biopet/pipelines/shiva/sampleVariants.ssp"),
14
15
16
17
18
        "QC reads" -> ReportSection("/nl/lumc/sasc/biopet/pipelines/flexiprep/flexiprepReadSummary.ssp"),
        "QC bases" -> ReportSection("/nl/lumc/sasc/biopet/pipelines/flexiprep/flexiprepBaseSummary.ssp")
      ), Map()),
      "Samples" -> generateSamplesPage(pageArgs)
    ),
Peter van 't Hof's avatar
Peter van 't Hof committed
19
    List("Report" -> ReportSection("/nl/lumc/sasc/biopet/pipelines/shiva/shivaFront.ssp")),
20
21
22
    pageArgs
  )

23
  def samplePage(sampleId: String, args: Map[String, Any]) = {
Peter van 't Hof's avatar
Peter van 't Hof committed
24
    ReportPage(Map("Libraries" -> generateLibraryPage(args)), List(
Peter van 't Hof's avatar
Peter van 't Hof committed
25
26
      "Libraries" -> ReportSection("/nl/lumc/sasc/biopet/core/report/librariesList.ssp"),
      "Variantcalling" -> ReportSection("/nl/lumc/sasc/biopet/pipelines/shiva/sampleVariants.ssp"),
27
28
      "QC reads" -> ReportSection("/nl/lumc/sasc/biopet/pipelines/flexiprep/flexiprepReadSummary.ssp"),
      "QC bases" -> ReportSection("/nl/lumc/sasc/biopet/pipelines/flexiprep/flexiprepBaseSummary.ssp")
29
30
31
32
    ), args)
  }

  def libraryPage(libId: String, args: Map[String, Any]) = {
33
    ReportPage(Map("QC" -> FlexiprepReport.indexPage), List(
34
35
36
      "QC reads" -> ReportSection("/nl/lumc/sasc/biopet/pipelines/flexiprep/flexiprepReadSummary.ssp"),
      "QC bases" -> ReportSection("/nl/lumc/sasc/biopet/pipelines/flexiprep/flexiprepBaseSummary.ssp")
    ), args)
37
38
39
40
41
42
  }

  def reportName = "Title Test"

  // FIXME: Not yet finished
}