The PDF of the difference between a gamma and a negative exponential distribution. The shape and rate of the gamma are a and r.
This comes from the convolution of the two distributions, which is also a gamma, and the integral of the new gamma evaluated with pgamma.
1 2 | dgammaMinusdexp(z, mean, sd, lambda, draws = 10000, div = 0.01,
xrange = c(0, 25), xmax = 4, graphit = F)
|
z |
A numeric vector. |
mean, sd |
The mean and sd of the gamma. |
lambda |
Rate of the exponential. |
graphit |
Logical; if |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.