MCPcopy Index your code
hub / github.com/clips/pattern / pdf

Function pdf

pattern/metrics.py:914–918  ·  view source on GitHub ↗

Probability density function.

(x, mu=0, sigma=1)

Source from the content-addressed store, hash-verified

912 return min(1.0, 0.5 * erfc((-x + mu) / (sigma * 2**0.5)))
913
914def pdf(x, mu=0, sigma=1):
915 """ Probability density function.
916 """
917 u = (x - mu) / abs(sigma)
918 return (1 / sqrt(2*pi) * abs(sigma)) * exp(-u*u / 2)
919
920def tpdf(x, df):
921 """ Probability density function for the Student's t-distribution.

Callers

nothing calls this directly

Calls 1

absFunction · 0.50

Tested by

no test coverage detected