Skip to contents

Plot the Significant Differences from a Permutation Test

Usage

# S3 method for class 'tna_permutation'
plot(x, colors, posCol = "#009900", negCol = "red", edge_labels = TRUE, ...)

Arguments

x

A tna_permutation object.

colors

See cograph::splot().

posCol

Color for plotting edges the difference in edge weights is positive. See cograph::splot().

negCol

Color for plotting edges when the the difference in edge weights is negative. See cograph::splot().

edge_labels

Boolean indicating whether edge labels should be ploted. Defaults to TRUE

...

Additional arguments passed to the permutation renderer of cograph::splot(). In addition to the usual styling arguments, this includes permutation-specific options such as show_nonsig (also draw non-significant edges), show_stars (annotate edge labels with significance stars), show_effect (annotate edge labels with effect sizes), and the styling of non-significant edges via edge_nonsig_color, edge_nonsig_style, and edge_nonsig_alpha.

Value

A cograph_network object containing the significant edges (and, when show_nonsig = TRUE, the non-significant edges) according to the permutation test.

Examples

model_x <- tna(group_regulation[1:200, ])
model_y <- tna(group_regulation[1001:1200, ])
# Small number of iterations for CRAN
perm <- permutation_test(model_x, model_y, iter = 20)
plot(perm)