Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Mirrors
biopet.biopet
Commits
2ce81c48
Commit
2ce81c48
authored
Jun 29, 2015
by
Peter van 't Hof
Browse files
Changes method name
parent
ae94babe
Changes
7
Hide whitespace changes
Inline
Side-by-side
public/bammetrics/src/main/resources/nl/lumc/sasc/biopet/pipelines/bammetrics/bammetricsInputFile.ssp
View file @
2ce81c48
...
...
@@ -13,8 +13,8 @@
</tr></thead>
<tbody>
<tr>
<td>${summary.get
Library
Value(sampleId, libId, metricsTag, "files", "pipeline", "bamfile", "path")}</td>
<td>${summary.get
Library
Value(sampleId, libId, metricsTag, "files", "pipeline", "bamfile", "md5")}</td>
<td>${summary.getValue(sampleId, libId, metricsTag, "files", "pipeline", "bamfile", "path")}</td>
<td>${summary.getValue(sampleId, libId, metricsTag, "files", "pipeline", "bamfile", "md5")}</td>
</tr>
</tbody>
</table>
\ No newline at end of file
public/bammetrics/src/main/resources/nl/lumc/sasc/biopet/pipelines/bammetrics/covstatsPlot.ssp
View file @
2ce81c48
...
...
@@ -10,11 +10,11 @@
<%@ var metricsTag: String = "bammetrics" %>
<%@ var target: String %>
#{
val originalPlot = new File(summary.get
Library
Value(sampleId, libId, metricsTag, "files", target + "_cov_stats", "plot", "path")
val originalPlot = new File(summary.getValue(sampleId, libId, metricsTag, "files", target + "_cov_stats", "plot", "path")
.getOrElse(throw new IllegalArgumentException("No plot found in summary")).toString)
val plot = new File(outputDir, target + "_cov_stats.png")
val values = summary.get
Library
Value(sampleId, libId, metricsTag, "stats", target + "_cov_stats", "coverage", "_all")
val values = summary.getValue(sampleId, libId, metricsTag, "stats", target + "_cov_stats", "coverage", "_all")
.getOrElse(throw new IllegalArgumentException("No plot found in summary")).asInstanceOf[Map[String, Any]]
if (originalPlot.exists()) IoUtils.copyFile(originalPlot, plot)
...
...
public/bammetrics/src/main/scala/nl/lumc/sasc/biopet/pipelines/bammetrics/BammetricsReport.scala
View file @
2ce81c48
...
...
@@ -42,8 +42,8 @@ object BammetricsReport extends ReportBuilder {
libId
:
Option
[
String
],
metricsTag
:
String
=
"bammetrics"
)
=
{
val
targets
=
(
summary
.
get
Library
Value
(
sampleId
,
libId
,
"bammetrics"
,
"settings"
,
"amplicon_name"
),
summary
.
get
Library
Value
(
sampleId
,
libId
,
"bammetrics"
,
"settings"
,
"roi_name"
)
summary
.
getValue
(
sampleId
,
libId
,
"bammetrics"
,
"settings"
,
"amplicon_name"
),
summary
.
getValue
(
sampleId
,
libId
,
"bammetrics"
,
"settings"
,
"roi_name"
)
)
match
{
case
(
Some
(
amplicon
:
String
),
Some
(
roi
:
List
[
_
]))
=>
amplicon
::
roi
.
map
(
_
.
toString
)
case
(
_
,
Some
(
roi
:
List
[
_
]))
=>
roi
.
map
(
_
.
toString
)
...
...
public/biopet-framework/src/main/resources/nl/lumc/sasc/biopet/core/report/executables.ssp
View file @
2ce81c48
...
...
@@ -6,7 +6,7 @@
<%@ var libId: Option[String] = None %>
<%@ var pipeline: String = summary.getValue("meta", "pipeline_name").getOrElse("").toString %>
#{
val executables = summary.get
Library
Value(sampleId, libId, pipeline, "executables").getOrElse(Map()).asInstanceOf[Map[String, Map[String, Any]]]
val executables = summary.getValue(sampleId, libId, pipeline, "executables").getOrElse(Map()).asInstanceOf[Map[String, Map[String, Any]]]
}#
<table class="table">
...
...
public/biopet-framework/src/main/scala/nl/lumc/sasc/biopet/core/summary/Summary.scala
View file @
2ce81c48
...
...
@@ -55,7 +55,7 @@ class Summary(file: File) {
//TODO: rename method
/** Get value on nested path with prefix depending is sampleId and/or libId is None or not */
def
get
Library
Value
(
sampleId
:
Option
[
String
],
libId
:
Option
[
String
],
path
:
String*
)
:
Option
[
Any
]
=
{
def
getValue
(
sampleId
:
Option
[
String
],
libId
:
Option
[
String
],
path
:
String*
)
:
Option
[
Any
]
=
{
(
sampleId
,
libId
)
match
{
case
(
Some
(
sample
),
Some
(
lib
))
=>
getLibraryValue
(
sample
,
lib
,
path
:
_
*
)
case
(
Some
(
sample
),
_
)
=>
getSampleValue
(
sample
,
path
:
_
*
)
...
...
public/mapping/src/main/resources/nl/lumc/sasc/biopet/pipelines/mapping/outputBamfiles.ssp
View file @
2ce81c48
...
...
@@ -48,8 +48,8 @@
#for (libId <- libs)
#if (libs.head != libId) <tr> #end
#if (!sampleLevel) <td><a href="${rootPath}Samples/${sample}/Libraries/${libId}/index.html">${libId}</a></td> #end
<td>${removeDir(summary.get
Library
Value(Some(sample), (if (sampleLevel) None else Some(libId)), pipelineName, "files", "pipeline", fileTag, "path"))}</td>
<td>${summary.get
Library
Value(Some(sample), (if (sampleLevel) None else Some(libId)), pipelineName, "files", "pipeline", fileTag, "md5")}</td>
<td>${removeDir(summary.getValue(Some(sample), (if (sampleLevel) None else Some(libId)), pipelineName, "files", "pipeline", fileTag, "path"))}</td>
<td>${summary.getValue(Some(sample), (if (sampleLevel) None else Some(libId)), pipelineName, "files", "pipeline", fileTag, "md5")}</td>
</tr>
#end
#end
...
...
public/shiva/src/main/resources/nl/lumc/sasc/biopet/pipelines/shiva/outputVcfFiles.ssp
View file @
2ce81c48
...
...
@@ -9,7 +9,7 @@
<%@ var rootPath: String %>
<%@ var outputDir: File %>
#{
val variantCallers = summary.get
Library
Value(sampleId, libId, "shivavariantcalling", "settings", "variantcallers").get.asInstanceOf[List[String]]
val variantCallers = summary.getValue(sampleId, libId, "shivavariantcalling", "settings", "variantcallers").get.asInstanceOf[List[String]]
val pipelineOutputDir = summary.getValue("meta", "output_dir").getOrElse("").toString
def removeDir(value: Option[Any]): Option[Any] = {
value.collect { case a =>
...
...
@@ -31,15 +31,15 @@
#if (variantCallers.size > 1)
<tr>
<td>Final (merged)</td>
<td>${removeDir(summary.get
Library
Value(sampleId, libId, "shivavariantcalling", "files", "pipeline", "final", "path"))}</td>
<td>${summary.get
Library
Value(sampleId, libId, "shivavariantcalling", "files", "pipeline", "final", "md5")}</td>
<td>${removeDir(summary.getValue(sampleId, libId, "shivavariantcalling", "files", "pipeline", "final", "path"))}</td>
<td>${summary.getValue(sampleId, libId, "shivavariantcalling", "files", "pipeline", "final", "md5")}</td>
</tr>
#end
#for (variantCaller <- variantCallers)
<tr>
<td>${variantCaller}</td>
<td>${removeDir(summary.get
Library
Value(sampleId, libId, "shivavariantcalling", "files", "pipeline", variantCaller, "path"))}</td>
<td>${summary.get
Library
Value(sampleId, libId, "shivavariantcalling", "files", "pipeline", variantCaller, "md5")}</td>
<td>${removeDir(summary.getValue(sampleId, libId, "shivavariantcalling", "files", "pipeline", variantCaller, "path"))}</td>
<td>${summary.getValue(sampleId, libId, "shivavariantcalling", "files", "pipeline", variantCaller, "md5")}</td>
</tr>
#end
</tbody>
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment