SinglePicto | R Documentation |
Creates a single pictograph. Allows customization of the number of icons and dimensions.
SinglePicto(
x,
total.icons = NA,
image = "star",
base.image = "",
is.custom.url = FALSE,
number.rows = NA,
number.cols = NA,
width.height.ratio = 1,
layout = NA,
scale = 1,
maximum.value = NA,
hide.base.image = FALSE,
fill.direction = "fromleft",
fill.icon.color = "black",
base.icon.color = "",
background.color = "transparent",
auto.size = FALSE,
icon.width = 50,
pad.row = 0,
pad.col = 0,
margin = 0,
margin.top = margin,
margin.right = margin,
margin.bottom = margin,
margin.left = margin,
label.data.position = c("None", "Above", "Below")[1],
label.data.digits = 0,
label.data.bigmark = ",",
label.data.prefix = "",
label.data.suffix = "",
label.data.100prc = FALSE,
label.data.font.weight = "normal",
label.data.font.size = 12,
label.data.font.family = "arial",
label.data.font.color = "#2C2C2C",
label.data.align.horizontal = "center",
graphic.width.inch = NA,
graphic.height.inch = NA,
graphic.resolution = 96,
print.config = FALSE,
x.limit = 1000
)
x |
Input data which determines the number of icons ( |
total.icons |
Total number of icons. Defaults to |
image |
The name of the icon to use (e.g. |
base.image |
The URL of the base image. Only used if |
is.custom.url |
When set to true, image is expected to be a URL to an jpeg or png image file available from online. |
number.rows |
If neither |
number.cols |
Maximum number of icons in each column. Overrides |
width.height.ratio |
Width to height ratio of pictograph if |
layout |
Optional parameter to determine how the layout is specified. Can be one of |
scale |
Scaling factor for |
maximum.value |
Maximum value |
hide.base.image |
Set to |
fill.direction |
Direction in which pictograph is filled (one of |
fill.icon.color |
Color of the filled icons. Only applicable for built-in icons. |
base.icon.color |
Color of the unfilled icons when |
background.color |
Color of the graphic background |
auto.size |
Automatically sizes the plot based on the size of the window/slot. |
icon.width |
Width of a single icon in pixels when |
pad.row |
Vertical space between icons. This should be a number between 0 (no space) and 1.0 (all space). |
pad.col |
Horizontal space between icons. |
margin |
Controls space on margins of the graphic. When |
margin.top |
Spacing on top of graphic. This value overrides |
margin.right |
Spacing on the right of the graphic. |
margin.bottom |
Spacing below graphic. |
margin.left |
Spacing on the left of the graphic. |
label.data.position |
One of |
label.data.digits |
Number of digits to show after decimal place. |
label.data.bigmark |
Option to prettify large numbers. By default a comma is placed after a thousand. |
label.data.prefix |
String to prepend data label. |
label.data.suffix |
String to append to data label. |
label.data.100prc |
Option to show data labels multiplied by 100. This is useful when reporting percentages. |
label.data.font.weight |
Weight of data labels, i.e. one of |
label.data.font.size |
Font size of data labels. |
label.data.font.family |
Font in which the data labels are displayed. |
label.data.font.color |
Font color of data labels. |
label.data.align.horizontal |
Horizontal alignment of data labels. |
graphic.width.inch |
(deprecated) Horizontal dimension of the chart output in inches. If these dimensions are not specified, the width-to-height ratio of the chart output may not match the desired dimensions. |
graphic.height.inch |
(deprecated) Verical dimension of the chart output in inches. |
graphic.resolution |
(deprecated) Conversion from inches to pixels. |
print.config |
If set to |
x.limit |
Upper limit of x above which |
PictographChart to create a chart or table of pictographs
xx <- 4
SinglePicto(xx)
SinglePicto(xx, total.icons=10, image="stickman", number.cols=5,
fill.icon.color="red", base.icon.color="deepskyblue")
SinglePicto(xx, 9, number.rows=3, is.custom.url=TRUE,
image="http://wiki.q-researchsoftware.com/images/9/91/Star_filled.svg",
base.image="http://wiki.q-researchsoftware.com/images/2/21/Star_unfilled.png")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.