Created
October 16, 2022 01:39
-
-
Save galenseilis/6aed1b8ebeee1e29217a357737620202 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from scipy.stats import beta | |
| import matplotlib.pyplot as plt | |
| import numpy as np | |
| params = [[81, 219], | |
| [82, 219], | |
| [81+100, 219+200]] | |
| for a, b in params: | |
| fig, ax = plt.subplots(1, 1) | |
| x = np.linspace(0.15, 0.40, 10000) | |
| y = beta.pdf(x, a, b) | |
| ax.plot(x, y, 'k') | |
| ax.set_xlabel('x') | |
| if a != 181: | |
| ax.set_ylabel(f'dbeta(x, {a}, {b})') | |
| else: | |
| ax.set_ylabel(f'dbeta(x, 81 + 100, 219 + 200)') | |
| plt.show() | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment