J'ai écrit une distribution logistique en utilisant numpy.
import numpy as np
from matplotlib import pyplot as plt
sigma = 1.0
mu = 0
x = np.arange(-5., 5., 0.001)
y = np.exp(-(x-mu)/sigma) / (sigma*(1+np.exp(-(x-mu)/sigma))**2)
plt.plot(x, y)
plt.show()
Comme ça.
Distribution cumulative
import numpy as np
from matplotlib import pyplot as plt
sigma = 1.0
mu = 0
x = np.arange(-5., 5., 0.001)
y = 1. /(1 + (np.exp(-(x-mu)/sigma)))
plt.plot(x, y)
plt.show()
Distribution normale avec numpy + matplotlib --Soleil cou coupé [Distribution logistique-Wikipedia](http://ja.wikipedia.org/wiki/%E3%83%AD%E3%82%B8%E3%82%B9%E3%83%86%E3%82%A3% E3% 83% 83% E3% 82% AF% E5% 88% 86% E5% B8% 83)
Recommended Posts