Created
March 4, 2012 15:07
-
-
Save pfmiles/1973428 to your computer and use it in GitHub Desktop.
Gaussian distribution function in python...
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def gauss_distr(mu, sigmaSquare, x): | |
from math import sqrt, pi, e | |
return (1 / sqrt(2 * pi * sigmaSquare)) * e ** ((-0.5) * (x - mu) ** 2 / sigmaSquare) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment