Skip to contents

Correlation between degree and abundance Graphing Pearson correlation between degree and abundance.

Usage

cor_degree_abs(g.list, abs.list, layer_names, layer_colors, title)

Arguments

g.list

List of igraph objects (multilayer network).

abs.list

List of abundances tables.

layer_names

The names of each layer of the network (ex. "control layer").

layer_colors

Assign a color to represent the layer (ex. "pink")

title

Plot's title.

Value

Returns a correlation plot between the degree and abundance of each node. It shows the R-square and p-value.

Examples


data("mlnet_dstoolAB")
data("tc_dstoolA")
data("tc_dstoolB")

# Create abundace list
lst <- list(tc_dstoolA, tc_dstoolB)

# Create a vector for layers' names
n <- c("Sample A", "Sample B")

cor_degree_abs (g.list = mlnet_dstoolAB, abs.list = lst, layer_names = n, layer_colors = c("green", "orange"), title = "Sample graph")