| plot_motifs | R Documentation |
Tab-completion-friendly wrapper around the
plot.cograph_motif_result S3 method. Functionally identical
to plot(x, ...) on a cograph_motif_result object,
but exposes the type / n / ncol / colors arguments to
editor autocompletion.
plot_motifs(
x,
type = c("triads", "types", "significance", "patterns"),
n = 15,
ncol = 5,
colors = c("#2166AC", "#B2182B"),
node_size = 5,
label_size = 11,
title_size = 12,
stats_size = 13,
legend_size = 13,
legend = TRUE,
motif_color = "#800020",
spacing = 1,
base_size = 12,
...
)
x |
A |
type |
Plot type:
|
n |
Maximum number of items to plot. Default 15. |
ncol |
Number of columns in the triad/pattern grid. Default 5. |
colors |
Two-element color vector mapped to a three-tone
significance scale (used by |
node_size |
Triad node radius (relative). Default 5.
( |
label_size |
Triad node-label font size in points. Default 11. |
title_size |
Per-panel title font size in points. Default 12. |
stats_size |
Per-panel statistics caption font size in points
(e.g., |
legend_size |
Bottom legend font size in points. Default 13. |
legend |
Logical. Show the abbreviation legend strip below the
triad grid. Default |
motif_color |
Color of triad nodes/edges/labels. Default
|
spacing |
Triangle spread inside each panel; |
base_size |
Base font size for the |
... |
Additional arguments passed to internal plot helpers. |
Invisibly returns the input x (or the underlying
ggplot for the "types" and "significance"
types, matching the S3 method).
motifs, subgraphs
## Not run:
g <- igraph::sample_gnp(20, 0.2, directed = TRUE)
m <- motifs(g)
plot_motifs(m)
plot_motifs(m, type = "types")
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.