Copula {copula} | R Documentation |
Density, distribution function, and random generation for a
copula
object.
dcopula(copula, u) pcopula(copula, u) rcopula(copula, n)
copula |
a "copula" object. |
u |
a vector of the copula dimension or a matrix with number of rows being the copula dimension, giving the coordinates of the points where the density or distribution function needs to be evaluated. |
n |
number of observations to be generated. |
The density function of an Archimedean copula was obtained by
differentiating the distribution function symbolically using
Mathematica and then processed by deriv
to give
algorithmic expressions. The maximum dimension implemented is 10 for
Clayton and Gumbel, and 6 for Frank.
The distribution function of a t
copula uses pmvt
from
package mvtnorm
. The density function of a t
copula uses the
dmst
from package sn
.
The random number generator for an Archimedean copula uses the conditional approach for the bivariate case and the Marshal-Olkin (1988) approach for dimension greater than 2.
"dcopula"
gives the density, "pcopula"
gives the
distribution function, and "rcopula"
generates random variates.
E.W. Frees and E.A. Valdez (1998). Understanding relationships using copulas. North American Actuarial Journal, 2:1–25.
C. Genest and A.-C. Favre (2007). Everything you always wanted to know about copula modeling but were afraid to ask. Journal of Hydrological Engineering, 12:347–368.
H. Joe (1997). Multivariate Models and Dependence Concepts. Chapman and Hall, London.
A.W. Marshal and I. Olkin (1988). Families of multivariate distributions. Journal of the American Statistical Association, 83:834–841.
R.B. Nelsen (2006). An introduction to Copulas. Springer, New York.
copula-class
,
ellipCopula
,
archmCopula
,
fgmCopula
.
norm.cop <- normalCopula(0.5) norm.cop x <- rcopula(norm.cop, 100) plot(x) dcopula(norm.cop, x) pcopula(norm.cop, x) persp(norm.cop, dcopula) contour(norm.cop, pcopula) ## a 3-dimensional normal copula u <- rcopula(normalCopula(0.5, dim = 3), 1000) ## scatterplot3d(u) ## a 3-dimensional clayton copula v <- rcopula(claytonCopula(2, dim = 3), 1000) ## scatterplot3d(v)