rvinecopulib (version 0.5.5.1.1)

bicop_dist: Bivariate copula models

Description

Create custom bivariate copula models by specifying the family, rotation, parameters, and variable types.

Usage

bicop_dist(
  family = "indep",
  rotation = 0,
  parameters = numeric(0),
  var_types = c("c", "c")
)

Arguments

family

the copula family, a string containing the family name (see Details for all possible families).

rotation

the rotation of the copula, one of 0, 90, 180, 270.

parameters

a vector or matrix of copula parameters.

var_types

variable types, a length 2 vector; e.g., c("c", "c") for both continuous (default), or c("c", "d") for first variable continuous and second discrete.

Value

An object of class bicop_dist, i.e., a list containing:

  • family, a character indicating the copula family.

  • rotation, an integer indicating the rotation (i.e., either 0, 90, 180, or 270).

  • parameters, a numeric vector or matrix of parameters.

  • npars, a numeric with the (effective) number of parameters.

  • var_types, the variable types.

Details

Implemented families

type name name in R
- Independence "indep"
Elliptical Gaussian "gaussian"
" Student t "student"
Archimedean Clayton "clayton"
" Gumbel "gumbel"
" Frank "frank"
" Joe "joe"
" Clayton-Gumbel (BB1) "bb1"
" Joe-Gumbel (BB6) "bb6"
" Joe-Clayton (BB7) "bb7"
" Joe-Frank (BB8) "bb8"
Nonparametric Transformation kernel "tll"

See Also

bicop_dist(), plot.bicop(), contour.bicop(), dbicop(), pbicop(), hbicop(), rbicop()

Examples

Run this code
# NOT RUN {
## Clayton 90<U+00B0> copula with parameter 3
cop <- bicop_dist("clayton", 90, 3)
cop
str(cop)

## visualization
plot(cop)
contour(cop)
plot(rbicop(200, cop))

## BB8 copula model for discrete data
cop_disc <- bicop_dist("bb8", 0, c(2, 0.5), var_types = c("d", "d"))
cop_disc

# }

Run the code above in your browser using DataCamp Workspace