vineOrder: Select an Order of the Variables

Description Usage Arguments Details Value References Examples

Description

Select an order of the variables. The order of the variables determines the bivariate dependencies that will be explicit modeled in the first tree of the vine.

Usage

1
vineOrder(type, data, method = "greedy", ...)

Arguments

type

Type of vine. Supported values: "CVine" and "DVine".

data

Data matrix of pseudo-observations.

method

Ordering method. Supported values: "random", "greedy".

...

Additional arguments for the order method.

Details

In D-vines, the order of the variables determines the structure of all the trees of the vine. This is not the case for C-vines where the root node of each tree can be selected.

The "random" method returns a random permutation of the variables.

The "greedy" method returns an order of the variables that intends to capture as much dependence as possible in the first tree of the vine. The method finds the order of the variables that defines a tree that maximizes a given dependence measure used as edge weights. For C-vines, it is determined iteratively checking each variable as root node. For D-vines, it is equivalent to solve the traveling salesman problem (TSP), see (Brechmann, 2010) for details. The TSP is solved using the cheapest insertion algorithm implemented by the solve_TSP function of the TSP package. The following are additional parameters for this method.

according

Dependence measure. The default value is "kendall" and supported values are:

"kendall"

Absolute value of Kendall's tau.

"spearman"

Absolute value of Spearman's rho.

"pearson"

Absolute value of Pearson's product moment correlation coefficient.

"df"

Smaller degrees of freedom of a bivariate t copula.

Value

A vector with the ordered indexes of the variables. This vector should be used to reorder the variables of the data matrix.

References

Brechmann, E. C. (2010) Truncated and simplified regular vines and their applications. Diploma thesis. Technische Universitaet Muenchen.

Examples

1
2
3
4
5
data <- matrix(runif(5 * 100), ncol = 5, nrow = 500)

vineOrder("CVine", data, method = "random")
vineOrder("DVine", data, method = "greedy",
          according = "spearman")

yasserglez/vines documentation built on June 9, 2021, 10:06 a.m.