Class and methods for 4-parameter beta distributions in regression specification using the workflow from the distributions3 package.
Usage
Beta4(mu, phi, theta1 = 0, theta2 = 1 - theta1)
Arguments
mu
numeric. The mean of the beta distribution that is extended to support [theta1, theta2].
phi
numeric. The precision parameter of the beta distribution that is extended to support [theta1, theta2].
theta1, theta2
numeric. The minimum and maximum, respectively, of the 4-parameter beta distribution. By default a symmetric support is chosen by theta2 = 1 - theta1 which reduces to the classic beta distribution because of the default theta1 = 0.
Details
The distribution is obtained by a linear transformation of a beta-distributed random variable with intercept theta1 and slope theta2 - theta1.
## all methods above can either be applied elementwise or for## all combinations of X and x, if length(X) = length(x),## also the result can be assured to be a matrix via drop = FALSEp<-c(0.05, 0.5, 0.95)quantile(X, p, elementwise =FALSE)