The normal distribution

The normal distribution may be plotted from sampled data as a histogram:

In [x]: import numpy as np
In [x]: import matplotlib.pyplot as plt
In [x]: mu, sigma = 100., 8.
In [x]: samples = np.random.normal(loc=mu, scale=sigma, size=10000)
In [x]: counts, bins, patches = plt.hist(samples, bins=100, normed=True)
In [x]: plt.plot(bins, 1/(sigma * np.sqrt(2 * np.pi)) *
...                np.exp( -(bins - mu)**2 / (2 * sigma**2) ), lw=2)
In [x]: plt.show()

The normal distribution