| plot_edge_diff_forest | R Documentation |
Plots pairwise edge weight differences from a boot_glasso object.
Each row (linear) or spoke (circular) is one edge pair. The square marks
the mean bootstrap difference, the bar spans its bootstrap percentile
interval at level 1 - alpha, and a dashed line or ring marks zero.
Significant pairs are plotted in pos_color when the first edge is
larger and in neg_color when the second edge is larger.
plot_edge_diff_forest(x, ...)
## S3 method for class 'boot_glasso'
plot_edge_diff_forest(
x,
alpha = NULL,
layout = c("linear", "circular", "chord", "tile"),
show_nonsig = FALSE,
nonzero_only = FALSE,
sort_by = c("estimate", "significance", "name"),
n_top = NULL,
pos_color = "#C0392B",
neg_color = "#2C6E8A",
nonsig_color = "#AAAAAA",
ring_color = "#C8C8C8",
label_size = 2.3,
label_color = NULL,
point_size = if (match.arg(layout) == "circular") 2 else 3,
r_inner = 0.38,
r_outer = 0.72,
title = NULL,
subtitle = NULL,
...
)
x |
A |
... |
Currently unused. |
alpha |
Significance threshold. Default |
layout |
|
show_nonsig |
Logical. Include non-significant pairs. Default
|
nonzero_only |
If |
sort_by |
|
n_top |
Restrict to top N pairs by absolute difference. |
pos_color |
Color when edge1 > edge2. Default |
neg_color |
Color when edge1 < edge2. Default |
nonsig_color |
Color for non-significant pairs. Default
|
ring_color |
Ring color (circular and chord layouts). Default
|
label_size |
Text size of edge labels (circular and chord layouts).
Default |
label_color |
Fixed label color (circular and chord layouts).
|
point_size |
Size of estimate square (linear and circular layouts).
Default |
r_inner |
Inner ring radius (circular). Default |
r_outer |
Outer ring radius (circular). Default |
title |
Plot title. Default |
subtitle |
Plot subtitle. Default |
A ggplot object.
set.seed(1)
data1 <- as.data.frame(matrix(rnorm(60), 20, 3, dimnames = list(NULL, c("A","B","C"))))
bg <- Nestimate::boot_glasso(data1, iter = 20, cs_iter = 10,
centrality = "strength")
plot_edge_diff_forest(bg, show_nonsig = TRUE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.