dgBetaD {sgr} | R Documentation |
Generalized Beta distribution for discrete variables
Description
Generalized Beta distribution for discrete variables.
Usage
dgBetaD(x, a = min(x), b = max(x), gam = 1, del = 1, ct = 1)
Arguments
x |
Vector of quantilies. |
a |
Minimum of range of r.v. |
b |
Maximum of range of r.v. |
gam |
Gamma parameter. |
del |
Delta parameter. |
ct |
Correction term, default value: 1. |
Details
Let X
be a discrete r. v. with range
R_X=\{a,a+1,a+2,\ldots, a+t-1,a+t = b \}
and where a \in \mathrm{N} \cup \{0 \}
and t \in \mathrm{N}
. The Generalized Discrete Beta Distribution for the r.v. X
is defined as follows:
DG(x;a,b,\gamma,\delta)=
\left\{
\begin{array}{cl}
\frac{G^*(x;a,b,\gamma,\delta)}{\sum_{x' \in R_X} G^*(x';a,b,\gamma,\delta)} & x \in R_X\\
0 & x \notin R_X
\end{array}
\right.
where G^*
is a modified version of the generalized beta distribution dgBeta
defined as
G^*(x;a,b,\gamma,\delta)=\frac{1}{B(\gamma,\delta)(b-a+2c)^{\gamma+\delta-1}}
(x-a+c)^{\gamma-1}(b-x+c)^{\delta-1}
Value
Gives the density.
Author(s)
Massimiliano Pastore & Luigi Lombardi
References
Lombardi, L., Pastore, M. (2014). sgr: A Package for Simulating Conditional Fake Ordinal Data. The R Journal, 6, 164-177.
Pastore, M., Lombardi, L. (2014). The impact of faking on Cronbach's Alpha for dichotomous and ordered rating scores. Quality & Quantity, 48, 1191-1211.
See Also
Examples
x <- 1:7
GA <- c(1,3,1.5,8); DE <- c(1,3,4,2.5)
par(mfrow=c(2,2))
for (j in 1:4) {
plot(x,dgBetaD(x,gam=GA[j],del=DE[j]),type="h",
panel.first=points(x,dgBetaD(x,gam=GA[j],del=DE[j]),pch=19),
main=paste("gamma=",GA[j]," delta=",DE[j],sep=""),ylim=c(0,.6),
ylab="dgBetaD(x)")
}