Skip to content
Snippets Groups Projects
Commit d7177565 authored by bow's avatar bow
Browse files

Merge branch 'fix-vcffilter' into 'develop'

Fixed bug



See merge request !375
parents 180bb97e 9c002013
No related branches found
No related tags found
No related merge requests found
......@@ -263,7 +263,7 @@ object VcfFilter extends ToolCommand {
def minAlternateDepth(record: VariantContext, minAlternateDepth: Int, minSamplesPass: Int = 1): Boolean = {
record.getGenotypes.count(genotype => {
val AD = if (genotype.hasAD) List(genotype.getAD: _*) else Nil
if (AD.nonEmpty) AD.tail.count(_ >= minAlternateDepth) > 0 else true
if (AD.nonEmpty && minAlternateDepth >= 0) AD.tail.count(_ >= minAlternateDepth) > 0 else true
}) >= minSamplesPass
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment