cor_network_graph {heterocop}R Documentation

cor_network_graph

Description

This function enables the user to plot the graph corresponding to the correlations of the Gaussian copula

Usage

cor_network_graph(R, TS, binary = TRUE, legend)

Arguments

R

a correlation matrix of size dxd (d is the number of variables)

TS

a threshold for the absolute values of the correlation matrix coefficients

binary

a boolean specifying whether the coefficients should be binarized, TRUE by defaut (zero if the coefficient is less than the threshold in absolute value, 1 otherwise). If FALSE, the edge width is proportional to the coefficient value.

legend

a vector containing the type of each variable used to color the vertices

Value

a graph representing the correlations between the latent Gaussian variables

Examples

R <- diag_block_matrix(c(3,4,5),c(0.7,0.8,0.2))
data <- CopulaSim(20,R,c(rep("qnorm(0,1)",6),rep("qexp(0.5)",4),
rep("qbinom(4,0.8)",2)),random=FALSE)[[1]]
cor_network_graph(R,TS=0.3,binary=TRUE,legend=c(rep("Normal",6),
rep("Exponential",4),rep("Binomial",2)))


[Package heterocop version 0.1.0.0 Index]