plot_density: Plot density of empirical checkerboard copula

View source: R/plots.R

plot_densityR Documentation

Plot density of empirical checkerboard copula

Description

Plots the density/mass of the empirical checkerboard copula.

Usage

plot_density(
  mass_matrix,
  density = TRUE,
  color = "plasma",
  rb_values = c(10, 0.315, 0.15)
)

Arguments

mass_matrix

a squared matrix containing the mass distribution, e.g. output of the function emp_c_copula().

density

a logical (TRUE = default) whether the density or the mass is plotted.

color

Select the color palette. Options are c("plasma" (default), "viridis", "inferno", "magma", "cividis").

rb_values

a vector of size 3 with number of values, start value and end value in the rainbow colors space.

Value

a density plot (or mass distribution)

Examples

n <- 1000
x <- runif(n,0,1)
y <- runif(n,0,1)
plot(x,y,pch = 16)

mass <- ECBC(x,y,resolution = 10)
plot_density(mass, density=TRUE)
plot_density(mass, density=FALSE)

qad documentation built on Dec. 28, 2022, 2:54 a.m.