Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

biplackettcopUC

Plackett's Bivariate Copula


Description

Density, distribution function, and random generation for the (one parameter) bivariate Plackett copula.

Usage

dbiplackcop(x1, x2, oratio, log = FALSE)
pbiplackcop(q1, q2, oratio)
rbiplackcop(n, oratio)

Arguments

x1, x2, q1, q2

vector of quantiles.

n

number of observations. Same as in runif.

oratio

the positive odds ratio psi.

log

Logical. If TRUE then the logarithm is returned.

Details

See biplackettcop, the VGAM family functions for estimating the parameter by maximum likelihood estimation, for the formula of the cumulative distribution function and other details.

Value

dbiplackcop gives the density, pbiplackcop gives the distribution function, and rbiplackcop generates random deviates (a two-column matrix).

Author(s)

T. W. Yee

References

Mardia, K. V. (1967). Some contributions to contingency-type distributions. Biometrika, 54, 235–249.

See Also

Examples

## Not run:  N <- 101; oratio <- exp(1)
x <- seq(0.0, 1.0, len = N)
ox <- expand.grid(x, x)
zedd <- dbiplackcop(ox[, 1], ox[, 2], oratio = oratio)
contour(x, x, matrix(zedd, N, N), col = "blue")
zedd <- pbiplackcop(ox[, 1], ox[, 2], oratio = oratio)
contour(x, x, matrix(zedd, N, N), col = "blue")

plot(rr <- rbiplackcop(n = 3000, oratio = oratio))
par(mfrow = c(1, 2))
hist(rr[, 1])  # Should be uniform
hist(rr[, 2])  # Should be uniform

## End(Not run)

VGAM

Vector Generalized Linear and Additive Models

v1.1-5
GPL-3
Authors
Thomas Yee [aut, cre], Cleve Moler [ctb] (author of several LINPACK routines)
Initial release
2021-01-13

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.