powerlaw
powerlaw copied to clipboard
divide by 0 warnings
let me suggest using
(Theoretical_CDF * (1 - Theoretical_CDF)+0.0000001)
on line 700 of
Another good option would be to use the machine precision epsilon for floating number:
(Theoretical_CDF * (1 - Theoretical_CDF)+np.finfo(float).eps) # machine precision epsilon
A previous definition eps = np.finfo(float).eps # machine precision epsilon
could also make the code more readable