Skip to content
GitLab
Menu
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
e2dd034b
Commit
e2dd034b
authored
Jan 04, 2017
by
Peter van 't Hof
Browse files
Fixed report issues
parent
de357a4f
Changes
2
Hide whitespace changes
Inline
Side-by-side
shiva/src/main/resources/nl/lumc/sasc/biopet/pipelines/shiva/sampleVariants.ssp
View file @
e2dd034b
...
...
@@ -77,7 +77,7 @@
#for (sample <- samples.toList.sorted)
<tr><td><a href="${rootPath}Samples/${sample}/index.html">${sample}</a></td>
#for (field <- fields)
<td>${summary.get
SampleValue(sample,
"shivavariantcalling", "stats", vcfstatsKey, "
genotype"
, field)}</td>
<td>${summary.get
Value(
"shivavariantcalling", "stats", vcfstatsKey, "
total", "genotype", "general", sample
, field)}</td>
#end
</tr>
#end
...
...
shiva/src/main/scala/nl/lumc/sasc/biopet/pipelines/shiva/ShivaReport.scala
View file @
e2dd034b
...
...
@@ -139,15 +139,15 @@ trait ShivaReportTrait extends MultisampleMappingReportTrait {
if
(
libraryLevel
)
tsvWriter
.
print
(
"Library"
)
else
tsvWriter
.
print
(
"Sample"
)
tsvWriter
.
println
(
"\tHomVar\tHet\tHomRef\tNoCall"
)
def
getLine
(
summary
:
Summary
,
sample
:
String
,
lib
:
Option
[
String
]
=
None
)
:
String
=
{
def
getLine
(
summary
:
Summary
,
sample
:
String
,
summarySample
:
Option
[
String
],
lib
:
Option
[
String
]
=
None
)
:
String
=
{
val
path
=
target
match
{
case
Some
(
t
)
=>
List
(
"shivavariantcalling"
,
"stats"
,
s
"multisample-vcfstats-$caller-$t"
,
"genotype"
)
case
_
=>
List
(
"shivavariantcalling"
,
"stats"
,
s
"multisample-vcfstats-$caller"
,
"
genotype"
)
case
Some
(
t
)
=>
List
(
"shivavariantcalling"
,
"stats"
,
s
"multisample-vcfstats-$caller-$t"
,
"genotype"
,
sample
)
case
_
=>
List
(
"shivavariantcalling"
,
"stats"
,
s
"multisample-vcfstats-$caller"
,
"
total"
,
"genotype"
,
"general"
,
sample
)
}
val
homVar
=
new
SummaryValue
(
path
:+
"HomVar"
,
summary
,
Some
(
s
ample
)
,
lib
).
value
.
getOrElse
(
0
).
toString
.
toLong
val
homRef
=
new
SummaryValue
(
path
:+
"HomRef"
,
summary
,
Some
(
s
ample
)
,
lib
).
value
.
getOrElse
(
0
).
toString
.
toLong
val
noCall
=
new
SummaryValue
(
path
:+
"NoCall"
,
summary
,
Some
(
s
ample
)
,
lib
).
value
.
getOrElse
(
0
).
toString
.
toLong
val
het
=
new
SummaryValue
(
path
:+
"Het"
,
summary
,
Some
(
s
ample
)
,
lib
).
value
.
getOrElse
(
0
).
toString
.
toLong
val
homVar
=
new
SummaryValue
(
path
:+
"HomVar"
,
summary
,
summaryS
ample
,
lib
).
value
.
getOrElse
(
0
).
toString
.
toLong
val
homRef
=
new
SummaryValue
(
path
:+
"HomRef"
,
summary
,
summaryS
ample
,
lib
).
value
.
getOrElse
(
0
).
toString
.
toLong
val
noCall
=
new
SummaryValue
(
path
:+
"NoCall"
,
summary
,
summaryS
ample
,
lib
).
value
.
getOrElse
(
0
).
toString
.
toLong
val
het
=
new
SummaryValue
(
path
:+
"Het"
,
summary
,
summaryS
ample
,
lib
).
value
.
getOrElse
(
0
).
toString
.
toLong
val
sb
=
new
StringBuffer
()
if
(
lib
.
isDefined
)
sb
.
append
(
sample
+
"-"
+
lib
.
get
+
"\t"
)
else
sb
.
append
(
sample
+
"\t"
)
sb
.
append
(
homVar
+
"\t"
)
...
...
@@ -162,11 +162,11 @@ trait ShivaReportTrait extends MultisampleMappingReportTrait {
sample
<-
summary
.
samples
if
sampleId
.
isEmpty
||
sample
==
sampleId
.
get
;
lib
<-
summary
.
libraries
(
sample
)
)
{
tsvWriter
.
println
(
getLine
(
summary
,
sample
,
Some
(
lib
)))
tsvWriter
.
println
(
getLine
(
summary
,
sample
,
sampleId
,
Some
(
lib
)))
}
}
else
{
for
(
sample
<-
summary
.
samples
if
sampleId
.
isEmpty
||
sample
==
sampleId
.
get
)
{
tsvWriter
.
println
(
getLine
(
summary
,
sample
))
tsvWriter
.
println
(
getLine
(
summary
,
sample
,
sampleId
))
}
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a 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