Division by zero bug in denovo probabilities
Background
In special cases, where PL values are very high, the denovo probability calculations may break down due to floating point rounding and cause a division-by-zero error.
Example (DMG): analysis ID 39397
Implementation
Since this is of the form k_i/sum(k)
(and k_i >= 0
for all i
), we simplify in these edge cases where sum(k) == 0
(meaning k_i == 0) and return 0.
Edited by Morten C. Eike