Learn R Programming

VineCopula (version 1.6-1)

BiCopLambda: Lambda-Function (Plot) for Bivariate Copula Data

Description

This function plots/returns the lambda-function of given bivariate copula data.

Usage

BiCopLambda(u1 = NULL, u2 = NULL, family = "emp",
            par = 0, par2 = 0, PLOT = TRUE, obj = NULL, ...)

Arguments

u1, u2
Data vectors of equal length with values in [0,1] (default: u1 and u2 = NULL).
family
An integer defining the bivariate copula family or indicating the empirical lambda-function: "emp" = empirical lambda-function (default) 1 = Gaussian copula; the theoretical lambda-function is simulated (no closed formula avail
par
Copula parameter; if the empirical lambda-function is chosen, par = NULL or 0 (default).
par2
Second copula parameter for t-, BB1, BB6, BB7 and BB8 copulas (default: par2 = 0).
PLOT
Logical; whether the results are plotted. If PLOT = FALSE, the values empLambda and/or theoLambda are returned (see below; default: PLOT = TRUE).
...
Additional plot arguments.
obj
BiCop object containing the family and parameter specification.

Value

  • empLambdaIf the empirical lambda-function is chosen and PLOT=FALSE, a vector of the empirical lambda's is returned.
  • theoLambdaIf the theoretical lambda-function is chosen and PLOT=FALSE, a vector of the theoretical lambda's is returned.

Details

If the family and parameter specification is stored in a BiCop object obj, the alternative version BiCopLambda(obj, PLOT = TRUE, ...) can be used.

References

Genest, C. and L.-P. Rivest (1993). Statistical inference procedures for bivariate Archimedean copulas. Journal of the American Statistical Association, 88 (423), 1034-1043. Schepsmeier, U. (2010). Maximum likelihood estimation of C-vine pair-copula constructions based on bivariate copulas from different families. Diploma thesis, Technische Universitaet Muenchen. http://mediatum.ub.tum.de/?id=1079296.

See Also

BiCopMetaContour, BiCopKPlot, BiCopChiPlot, BiCop

Examples

Run this code
# Clayton and rotated Clayton copulas
n <- 1000
tau <- 0.5

# simulate from Clayton copula
fam <- 3  
theta <- BiCopTau2Par(fam, tau)
set.seed(123)
dat <- BiCopSim(n, fam, theta)

# create lambda-function plots
par(mfrow = c(1, 3))
BiCopLambda(dat[, 1], dat[, 2])  # empirical lambda-function	
BiCopLambda(family = fam, par = theta)	# theoretical lambda-function
BiCopLambda(dat[, 1], dat[, 2], family = fam, par = theta)	# both

# lambda-function of estimated copula
fit <- BiCopSelect(dat[, 1], dat[, 2])
par(mfrow = c(1, 1))
BiCopLambda(fit)

# simulate from rotated Clayton copula (90 degrees)
fam <- 23  
theta <- BiCopTau2Par(fam, -tau)
set.seed(123)
dat <- BiCopSim(n, fam, theta)
  
# rotate the data to standard Clayton copula data
rot_dat <- 1 - dat[, 1]

par(mfrow = c(1, 3))
BiCopLambda(rot_dat, dat[, 2])  # empirical lambda-function	
BiCopLambda(family = 3, par = -theta)	# theoretical lambda-function
BiCopLambda(rot_dat, dat[, 2], family = 3, par = -theta)	# both

Run the code above in your browser using DataLab