Skip to content

Commit a223a54

Browse files
authored
Merge pull request #43 from MurrellGroup/HB-exp
Fixing exp
2 parents b32cdb8 + 1a96110 commit a223a54

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/models/discrete_models/codon_models.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -293,7 +293,7 @@ function HB98_AAfit(alpha, nuc_matrix, AA_fitness; genetic_code = universal_code
293293
if abs(diff) < 0.001 #To catch the hole discontinuity a 2nd order approximation that is REALLY close.
294294
f_ab = 1 / 12 * (12 + diff * (6 + diff)) #1+0.5*diff
295295
else
296-
f_ab = diff / (1 - e^-diff)
296+
f_ab = diff / (1 - exp(-diff))
297297
end
298298
codon_matrix[p[1][1], p[1][2]] = alpha * nuc_matrix[p[2][2], p[2][3]] * f_ab
299299
end

0 commit comments

Comments
 (0)