bg__fit_gamma {M3Drop} | R Documentation |
Fits the parameters of a gamma distribution to a set of observations
bg__fit_gamma(x)
x |
vector of observations to fit. |
scale = var(x)/mean(x) shape = mean(x)/scale
list with two entries: shape and size.
# dat <- rgamma(100, 0.1, 1) # params <- bg__fit_gamma(dat)