Learn R Programming

treemapify (version 0.2.2)

ggplotify: Draw an exploratory treemap

Description

Takes a data frame of treemap coordinates produced by "treemapify" and draws an exploratory treemap. The output is a ggplot2 plot, so it can be further manipulated e.g. a title added.

Usage

ggplotify(treeMap, label.colour = "white", label.size.factor = 1, label.size.threshold = NULL, label.size.fixed = NULL, label.groups = TRUE, group.label.colour = "darkgrey", group.label.size.factor = 1, group.label.size.threshold = NULL, group.label.size.fixed = NULL)

Arguments

treeMap
a data frame of treemap coordinates produced by "treemapify"
label.colour
colour for individual rect labels; defaults to white
label.size.factor
scaling factor for text size of individual rect labels; defaults to 1
label.size.threshold
(optional) minimum text size for individual rect labels. Labels smaller than this threshold will not be displayed
label.size.fixed
(optional) fixed size for individual rect labels. Overrides label.size.factor
label.groups
should groups be labeled? (Individual observations will be automatically labelled if a "label" parameter was passed to "treemapify")
group.label.colour
colour for group labels; defaults to darkgrey
group.label.size.factor
scaling factor for text size of group labels; defaults to 1
group.label.size.threshold
(optional) minimum text size for group labels. Labels smaller than this threshold will not be displayed
group.label.size.fixed
(optional) fixed size for group labels. Overrides group.label.size.factor

See Also

Other treemapify: treemapify