Palm: Generates a palm tree plot from a table of data.

Description Usage Arguments Examples

View source: R/palm.R

Description

This function wraps the PalmTrees function in the rhtmlPalmTrees package and performs additional data preparation.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
Palm(table, global.font.family = "Arial", global.font.color = rgb(44,
  44, 44, maxColorValue = 255), title = "",
  title.font.family = global.font.family,
  title.font.color = global.font.color, title.font.size = 16,
  subtitle = "", subtitle.font.family = global.font.family,
  subtitle.font.color = global.font.color, subtitle.font.size = 12,
  footer = "", footer.font.family = global.font.family,
  footer.font.color = global.font.color, footer.font.size = 8,
  x.tick.font.family = global.font.family,
  x.tick.font.color = global.font.color, x.tick.font.size = 11,
  x.title = "", x.title.font.family = global.font.family,
  x.title.font.color = global.font.color, x.title.font.size = 12,
  legend.font.family = global.font.family,
  legend.font.color = global.font.color, legend.font.size = 11,
  legend.background.color = "transparent",
  legend.border.color = "#000000", y.axis.show = TRUE,
  tooltip.show = TRUE, y.tick.format = "",
  y.tick.font.family = global.font.family,
  y.tick.font.color = global.font.color, y.tick.font.size = 11,
  y.title = "", y.title.font.family = global.font.family,
  y.title.font.color = global.font.color, y.title.font.size = 12,
  y.tick.prefix = NULL, y.tick.suffix = NULL,
  hovertext.font.family = global.font.family, hovertext.font.size = 11,
  colors = NULL)

Arguments

table

A matrix of data to be displayed. Each row is represented by a palm tree, the value in each column determines the area of a leaf on each palm tree.

global.font.family

Character; font family for all occurrences of any font attribute for the chart unless specified individually.

global.font.color

Global font color as a named color in character format (e.g. "black") or an a hex code.

title

Character; chart title.

title.font.family

Character; title font family. Can be "Arial Black", "Arial", "Comic Sans MS", "Courier New", "Georgia", "Impact", "Lucida Console", "Lucida Sans Unicode", "Marlett", "Symbol", "Tahoma", "Times New Roman", "Trebuchet MS", "Verdana", "Webdings"

title.font.color

Title font color as a named color in character format (e.g. "black") or a hex code.

title.font.size

Integer; Title font size; default = 10.

subtitle

Character

subtitle.font.family

Character; subtitle font family

subtitle.font.color

subtitle font color as a named color in character format (e.g. "black") or an a hex code.

subtitle.font.size

Integer; subtitle font size

footer

Character

footer.font.family

Character; footer font family

footer.font.color

footer font color as a named color in character format (e.g. "black") or an a hex code.

footer.font.size

Integer; footer font size

x.tick.font.family

Character; x-axis tick label font family

x.tick.font.color

X-axis tick label font color as a named color in character format (e.g. "black") or an a hex code.

x.tick.font.size

Integer; x-axis tick label font size

x.title

Character, x-axis title; defaults to chart input values; to turn off set to "FALSE".

x.title.font.family

Character; x-axis title font family

x.title.font.color

x-axis title font color as a named color in character format (e.g. "black") or an a hex code.

x.title.font.size

Integer; x-axis title font size

legend.font.family

Character; legend font family.

legend.font.color

Legend font color as a named color in character format (e.g. "black") or a hex code.

legend.font.size

Integer; Legend font size.

legend.background.color

Background color of the legend.

legend.border.color

Color of the legend border.

y.axis.show

Logical; whether to show the y-axis.

tooltip.show

Logical; whether to show a tooltip on hover.

y.tick.format

A string representing a d3 formatting code. See https://github.com/d3/d3/blob/master/API.md#number-formats-d3-format

y.tick.font.family

Character; y-axis tick label font family

y.tick.font.color

y-axis tick label font color as a named color in character format (e.g. "black") or an a hex code.

y.tick.font.size

Integer; y-axis tick label font size

y.title

Character, y-axis title; defaults to chart input values; to turn off set to "FALSE".

y.title.font.family

Character; y-axis title font family

y.title.font.color

y-axis title font color as a named color in character format (e.g. "black") or a hex code.

y.title.font.size

Integer; y-axis title font size

y.tick.prefix

y-axis tick label prefix

y.tick.suffix

y-axis tick label suffix

hovertext.font.family

Font family of hover text.

hovertext.font.size

Font size of hover text.

colors

Character; a vector containing one or more colors specified as hex codes.

Examples

1
2
3
4
z <- matrix(runif(20), nrow = 4)
rownames(z) <- c("oak", "elm", "birch", "fir")
colnames(z) <- c("leaf", "frond", "twig", "branch", "stick")
Palm(z)

Displayr/flipStandardCharts documentation built on Nov. 20, 2019, 6:35 p.m.