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
df540400
Commit
df540400
authored
May 08, 2016
by
Peter van 't Hof
Browse files
Add exclusions for specific values
parent
2be8d063
Changes
1
Hide whitespace changes
Inline
Side-by-side
biopet-extensions/src/main/scala/nl/lumc/sasc/biopet/extensions/VariantEffectPredictor.scala
View file @
df540400
...
...
@@ -276,10 +276,17 @@ class VariantEffectPredictor(val root: Configurable) extends BiopetCommandLineFu
else
Map
()
}
protected
val
removeOnConflict
=
Set
(
"Output_file"
,
"Command_line_options"
,
"Run_time"
,
"Start_time"
,
"End_time"
,
"Input_file_(format)"
,
"Novel_/_existing_variants"
)
protected
val
nonNumber
=
Set
(
"VEP_version_(API)"
,
"Cache/Database"
,
"Species"
)
override
def
resolveSummaryConflict
(
v1
:
Any
,
v2
:
Any
,
key
:
String
)
:
Any
=
{
(
v1
,
v2
)
match
{
case
(
x1
:
Int
,
x2
:
Int
)
=>
x1
+
x2
case
_
=>
throw
new
IllegalStateException
(
s
"Value are not Int's, unable to sum them up, key: $key, v1: $v1, v2: $v2"
)
if
(
removeOnConflict
.
contains
(
key
))
None
else
if
(
nonNumber
.
contains
(
key
))
v1
else
{
(
v1
,
v2
)
match
{
case
(
x1
:
Int
,
x2
:
Int
)
=>
x1
+
x2
case
_
=>
throw
new
IllegalStateException
(
s
"Value are not Int's, unable to sum them up, key: $key, v1: $v1, v2: $v2"
)
}
}
}
...
...
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