| [ Web Proxy ] |
| Viewing: https://matplotlib.org/stable/api/_as_gen/../../plot_types/unstructured/../stats/ecdf.html | [Back] [Original] |
Note
Go to the end to download the full example code.
Compute and plot the empirical cumulative distribution function of x.
See ecdf.
[ecdf]import matplotlib.pyplot as plt
import numpy as np
plt.style.use('_mpl-gallery')
# make data
np.random.seed(1)
x = 4 + np.random.normal(0, 1.5, 200)
# plot:
fig, ax = plt.subplots()
ax.ecdf(x)
plt.show()
| Web Proxy Viewer | New URL | Original Page |