a master function for updating various attributes and
features of dendrogram objects.
Usage
set(dend, ...)
## S3 method for class 'dendrogram'
set(dend,
what = c("labels",
"labels_colors",
"labels_cex",
"labels_to_character",
"leaves_pch",
"leaves_cex",
"leaves_col",
"nodes_pch",
"nodes_cex",
"nodes_col",
"hang_leaves",
"rank_branches",
"branches_k_color",
"branches_k_lty",
"branches_col",
"branches_lwd",
"branches_lty",
"by_labels_branches_col",
"by_labels_branches_lwd",
"by_labels_branches_lty",
"clear_branches",
"clear_leaves"
),
value, ...)
## S3 method for class 'dendlist'
set(dend, ..., which)
## S3 method for class 'data.table'
set(...)
Arguments
dend
a tree (dendrogram, or dendlist)
...
passed to the specific function for more options.
what
a character indicating what is the property of
the tree that should be set/updated. (see the usage and the example section
for the different options)
value
an object with the value to set in the dendrogram tree.
(the type of the value depends on the "what")
which
an integer vector indicating, in the case "dend" is
a dendlist, on which of the trees should the modification be performed.
If missing - the change will be performed on all of dends in the dendlist.
Details
This is a wrapper function for many of the main tasks we
might wish to perform on a dendrogram before plotting.
The options of by_labels_branches_col, by_labels_branches_lwd, by_labels_branches_lty
have extra parameters: type, attr, TF_value. You can read more about them here:
branches_attr_by_labels
The "what" parameter" can accept the following options:
labels - set the labels (labels<-.dendrogram)
labels_colors - set the labels' colors (color_labels)
labels_cex - set the labels' size (assign_values_to_leaves_nodePar)
labels_to_character - set the labels' to be characters
leaves_pch - set the leaves' point type (assign_values_to_leaves_nodePar)
leaves_cex - set the leaves' point size (assign_values_to_leaves_nodePar)
leaves_col - set the leaves' point color (assign_values_to_leaves_nodePar)
nodes_pch - set the nodes' point type (assign_values_to_nodes_nodePar)
nodes_cex - set the nodes' point size (assign_values_to_nodes_nodePar)
nodes_col - set the nodes' point color (assign_values_to_nodes_nodePar)
hang_leaves - hang the leaves (hang.dendrogram)
branches_k_color - color the branches (color_branches), a k parameter needs to be supplied.
branches_k_lty - updates the lwd of the branches (similar to branches_k_color), a k parameter needs to be supplied.
branches_col - set the color of branches (assign_values_to_branches_edgePar)
branches_lwd - set the line width of branches (assign_values_to_branches_edgePar)
branches_lty - set the line type of branches (assign_values_to_branches_edgePar)
by_labels_branches_col - set the color of branches with specific labels (branches_attr_by_labels)
by_labels_branches_lwd - set the line width of branches with specific labels (branches_attr_by_labels)
by_labels_branches_lty - set the line type of branches with specific labels (branches_attr_by_labels)