View source: R/betafunctions.R
pGammaBinom | R Documentation |
Extends the cumulative Binomial probability mass function to positive non-integers, effectively turning the mass-function into a density-function.
pGammaBinom(q, size, prob, lower.tail = TRUE)
q |
Vector of quantiles. |
size |
Number of "trials" (zero or more). Need not be integer. |
prob |
Probability of "success" on each "trial". Need not be integer. |
lower.tail |
Logical. If TRUE (default), probabilities are P[X<x], otherwise, P[X >= x]. Note that this differs from base-R |
Loeb, D. E. (1992). A generalization of the binomial coefficients. Discrete Mathematics, 105(1-3).
# Assume some variable follows a Gamma-Binomial distribution with
# "number of trials" = 10.5 and probability of "success" for each "trial"
# = 0.75, to compute the cumulative probability to attain a "number of
# success" below a specific point (e.g., less than 7.5 "successes":
pGammaBinom(q = 7.5, size = 10.5, prob = 0.75)
# Conversely, to attain a value at or above 7.5:
pGammaBinom(q = 7.5, size = 10.5, prob = 0.75, lower.tail = FALSE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.