Closed dwinter closed 9 years ago
Digging a little deeper on this, I can at least find the value that kills it
dfe:::NG_convolution(Beta=13, Ve=1e-4, a=2, k=15, z=0.889)
There is a bit of a spike in the function near this fitness value, taking values to the left and the right:
sapply(seq(0.885, 0.888, 0.001), dfe:::NG_convolution, Beta=13, Ve=1e-4, a=2, k=15)
sapply(seq(0.890, 0.895, 0.001), dfe:::NG_convolution, Beta=13, Ve=1e-4, a=2, k=15)
This bug is closed since moving to GSL for integration
At present, some fitness values, including those simulated with our
rma_gamma
function, break they density function. There doesn't seem to be any rhyme or reason to which fitness values do this, but they occur most often when the mean effect of mutations islarge, and the mutation rate is low:One work around, as demonstrated above, might be to catch these errors and take values very-slightly either side of the error-producing one. This likely relates to the errors we want to catch in #2 .