# NOT RUN {
Gamma$new(shape = 1, rate = 2)
Gamma$new(shape = 1, scale = 4)
Gamma$new(shape = 1, mean = 0.5)
# Default is shape = 1, rate = 1
x = Gamma$new(verbose = TRUE)
# Update parameters
# When any parameter is updated, all others are too!
x$setParameterValue(scale = 2)
x$parameters()
# d/p/q/r
x$pdf(5)
x$cdf(5)
x$quantile(0.42)
x$rand(4)
# Statistics
x$mean()
x$variance()
summary(x)
# }
Run the code above in your browser using DataLab