Description Usage Arguments Details Value Note Author(s) References See Also Examples

Density, distribution function, quantile function and random
generation for the Dagum distribution with shape parameters `a`

and `p`

, and scale parameter `scale`

.

1 2 3 4 |

`x, q` |
vector of quantiles. |

`p` |
vector of probabilities. |

`n` |
number of observations. If |

`shape1.a, shape2.p` |
shape parameters. |

`scale` |
scale parameter. |

`log` |
Logical.
If |

`lower.tail, log.p` |
Same meaning as in |

See `dagum`

, which is the VGAM family function
for estimating the parameters by maximum likelihood estimation.

`ddagum`

gives the density,
`pdagum`

gives the distribution function,
`qdagum`

gives the quantile function, and
`rdagum`

generates random deviates.

The Dagum distribution is a special case of the 4-parameter generalized beta II distribution.

T. W. Yee and Kai Huang

Kleiber, C. and Kotz, S. (2003)
*Statistical Size Distributions in Economics and
Actuarial Sciences*,
Hoboken, NJ, USA: Wiley-Interscience.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 | ```
probs <- seq(0.1, 0.9, by = 0.1)
shape1.a <- 1; shape2.p <- 2
# Should be 0:
max(abs(pdagum(qdagum(p = probs, shape1.a = shape1.a, shape2.p = shape2.p),
shape1.a = shape1.a, shape2.p = shape2.p) - probs))
## Not run: par(mfrow = c(1, 2))
x <- seq(-0.01, 5, len = 401)
plot(x, dexp(x), type = "l", col = "black", ylab = "", las = 1, ylim = c(0, 1),
main = "Black is standard exponential, others are ddagum(x, ...)")
lines(x, ddagum(x, shape1.a = shape1.a, shape2.p = 1), col = "orange")
lines(x, ddagum(x, shape1.a = shape1.a, shape2.p = 2), col = "blue")
lines(x, ddagum(x, shape1.a = shape1.a, shape2.p = 5), col = "green")
legend("topright", col = c("orange","blue","green"), lty = rep(1, len = 3),
legend = paste("shape1.a =", shape1.a, ", shape2.p =", c(1, 2, 5)))
plot(x, pexp(x), type = "l", col = "black", ylab = "", las = 1,
main = "Black is standard exponential, others are pdagum(x, ...)")
lines(x, pdagum(x, shape1.a = shape1.a, shape2.p = 1), col = "orange")
lines(x, pdagum(x, shape1.a = shape1.a, shape2.p = 2), col = "blue")
lines(x, pdagum(x, shape1.a = shape1.a, shape2.p = 5), col = "green")
legend("bottomright", col = c("orange","blue","green"), lty = rep(1, len = 3),
legend = paste("shape1.a =", shape1.a, ", shape2.p =", c(1, 2, 5)))
## End(Not run)
``` |

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.