| nmf.rrr.DOT | R Documentation |
nmfae.DOT generates a DOT language string for visualizing the structure
of a three-layer NMF model. Two graph types are supported:
"XCX" shows encoder factors, \Theta, and decoder factors;
"YXCXY" shows the full structure from Y_2 through X_2, \Theta,
X_1 to Y_1.
Edge widths are proportional to matrix element values, and edges below
threshold are omitted for clarity.
nmf.rrr.DOT(
result,
type = c("XCX", "YXCXY"),
threshold = 0.01,
sig.level = 0.1,
rankdir = "LR",
fill = TRUE,
weight_scale = 5,
weight_scale_x1 = weight_scale,
weight_scale_theta = weight_scale,
weight_scale_x2 = weight_scale,
Y1.label = NULL,
X1.label = NULL,
X2.label = NULL,
Y2.label = NULL,
Y1.title = "Output (Y1)",
X1.title = "Response (X1)",
X2.title = "Covariate (X2)",
Y2.title = "Input (Y2)",
hide.isolated = TRUE
)
result |
An object of class |
type |
Character. Graph type: |
threshold |
Numeric. Edges with values below this are omitted. Default is 0.01. |
sig.level |
Numeric or |
rankdir |
Character. Graph direction for DOT layout. Default is |
fill |
Logical. If |
weight_scale |
Numeric. Base scale factor for edge widths. Default is 5. |
weight_scale_x1 |
Numeric. Scale factor for |
weight_scale_theta |
Numeric. Scale factor for |
weight_scale_x2 |
Numeric. Scale factor for |
Y1.label |
Character vector of output variable labels. |
X1.label |
Character vector of decoder basis labels. |
X2.label |
Character vector of encoder basis labels. |
Y2.label |
Character vector of input variable labels. |
Y1.title |
Character. Title for output node group. Default is |
X1.title |
Character. Title for the response-basis node group. Default is |
X2.title |
Character. Title for the covariate-basis node group. Default is |
Y2.title |
Character. Title for input node group. Default is |
hide.isolated |
Logical. If |
A character string containing the DOT graph specification.
This function is experimental. The interface may change in future versions; details are to be described in an upcoming paper.
nmfae
set.seed(1)
Y <- matrix(runif(20), nrow = 4)
res <- nmf.rrr(Y, rank1 = 2)
dot <- nmf.rrr.DOT(res)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.