Given a cluster structure determined by ICLUST
, create a rgraphic directly using Rgraphviz. To create dot code to describe the ICLUST
output with more precision, use ICLUST.graph
. As an option, dot code is also generated and saved in a file. To use the dot code, use either https://www.graphviz.org/ Graphviz or a commercial viewer (e.g., OmniGraffle).
ICLUST.rgraph(ic.results, out.file = NULL, min.size = 1, short = FALSE,
labels = NULL, size = c(8, 6), node.font = c("Helvetica", 14),
edge.font = c("Helvetica", 10), rank.direction=c("RL","TB","LR","BT"),
digits = 2, title = "ICLUST",label.font=2, ...)
output list from ICLUST
File name to save optional dot code.
draw a smaller node (without all the information) for clusters < min.size -- useful for large problems
if short==TRUE, don't use variable names
vector of text labels (contents) for the variables
size of output
Font to use for nodes in the graph
Font to use for the labels of the arrows (edges)
LR or TB or RL
number of digits to show
any title
The variable labels can be a different size than the other nodes. This is particularly helpful if the number of variables is large or the labels are long.
other options to pass
Output is a set of dot commands written either to console or to the output file. These commands may then be used as input to any "dot" viewer, e.g., Graphviz.
ICLUST.rgraph is a version of ICLUST.graph
that uses Rgraphviz to draw on the screen as well.
Additional output is drawn to main graphics screen.
Will create (or overwrite) an output file and print out the dot code to show a cluster structure. This dot file may be imported directly into a dot viewer (e.g., https://www.graphviz.org/). The "dot" language is a powerful graphic description language that is particulary appropriate for viewing cluster output. Commercial graphics programs (e.g., OmniGraffle) can also read (and clean up) dot files.
ICLUST.rgraph takes the output from ICLUST
results and processes it to provide a pretty picture of the results. Original variables shown as rectangles and ordered on the left hand side (if rank direction is RL) of the graph. Clusters are drawn as ellipses and include the alpha, beta, and size of the cluster. Edges show the cluster intercorrelations.
It is possible to trim the output to not show all cluster information. Clusters < min.size are shown as small ovals without alpha, beta, and size information.
ICLUST: https://personality-project.org/r/r.ICLUST.html
# NOT RUN {
test.data <- Harman74.cor$cov
ic.out <- ICLUST(test.data) #uses iclust.diagram instead
# }
Run the code above in your browser using DataLab