library(KendallSignature) library(rcdd) library(rgl) library(gMOIP) knitr::opts_chunk$set(collapse = TRUE, comment = "#>") knitr::knit_hooks$set(webgl = hook_webgl)
We will find the cut polytope of possible concordance probabilities in 3 dimensions. First, we find the vertices of the polytope of weights. These take a trivial form: they are the 4 vertices of the 4-dimensional simplex.
sig <- 1 names(sig) <- "empty" weights <- findpolytope(sig, d = 3) weights
Now we determine the correponding vertices of the polytope of concordance probabilities for the 3 pairs of random variables. There are 4 vertices: 3 vertices in which a single pair has concordance probability one and the others have concordance probability zero; 1 vertex in which all pairs have concordance probability 1.
allkappa <- Amatrix(3) %*% t(weights) k.vertices <- t(allkappa[-1, ]) k.vertices
We can display the polytope.
plot3d(k.vertices) plotHull3D(k.vertices)
We repeat the exercise for the polytope that describes the possible Kendall rank correlation matrices. This is the cut polytope.
alltau <- 2*allkappa -1 t.vertices <- t(alltau[-1, ]) t.vertices plot3d(t.vertices) plotHull3D(t.vertices)
Here is a positive-definite correlation matrix.
rho <- -5/12 P <- matrix(rho, nrow = 3, ncol = 3) + (1-rho)*diag(3) P eigen(P)$values
If this is a Kendall's tau matrix then the concordance signature is given by.
kappa <- c(1, (1 + P[lower.tri(P)])/2) kappa
The A matrix in 3 dimensions is easily computed.
Amatrix(3)
The extremal mixture weights must be:
solve(Amatrix(3), kappa)
But unfortunately this yields a negative weight, which is a contradiction. Observe how the point $(-5/12, -5/12, -5/12)$ is not in the cut polytope.
plotHull3D(c(-5/12, -5/12, -5/12))
Let's do the whole thing again but with a different rho value.
rho <- -1/3 P <- matrix(rho, nrow = 3, ncol = 3) + (1-rho)*diag(3) P eigen(P)$values
If this is a Kendall's tau matrix then the concordance signature is given by.
kappa <- c(1, (1 + P[lower.tri(P)])/2) kappa
The A matrix in 3 dimensions is easily computed.
Amatrix(3)
The extremal mixture weights must be:
solve(Amatrix(3), kappa)
This works fine. Note how the solution attaches zero weight to the first extremal copula and equal weight to the others. It is right on the boundary of the cut polytope.
plotHull3D(c(-1/3, -1/3, -1/3))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.