Jun-28-2018, 06:19 AM
To plot probability density distribution from empirical data you need to estimate probability density first.
One of the ways to do it is to use the kernel density estimation approach (see scipy's kde density estimator).
Also, you can use ready-made function from
One of the ways to do it is to use the kernel density estimation approach (see scipy's kde density estimator).
Also, you can use ready-made function from
seaborn
package. import seaborn as sns import numpy as np import matplotlib.pyplot as plt x=np.random.randn(10000) sns.distplot(x) #plots histogram and kde-estimation of the pdf. plt.show()