python求list的正态分布

import numpy as np
from scipy import stats
import matplotlib.pyplot as plt

x = np.array(peak_array)
y = stats.norm.pdf(x, 0, 1)

plt.plot(x, y)
plt.xlabel('x')
plt.ylabel('p')
plt.show()

你可能感兴趣的:(python求list的正态分布)