Probability, Probability Distributions, Probability Theory, Python, Statistics.
reject = 0.2 accept = 1 - reject px = [] for i in range(n+1): p = comb(10, i) * (reject ** i) * (accept ** (n - i)) px.append(p) px = np.array(px) plt.bar(x, px) plt.xlabel('trial(x = 1, 2, ...)') plt.ylabel('probability') plt.title('The PMF of Binomial Random Variable') plt.show() 3.4 Pascal