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
#Estimation, mean of Gamma(4.3, 6.2) with Accept-Reject Algorithm | |
from scipy.stats import gamma | |
import numpy as np | |
import matplotlib.pyplot as plt | |
def f(x): | |
r = gamma.pdf(x, 4.3, scale=1/6.2) | |
return r |