lm_piecharts | R Documentation |
Add a "piecharts" layer to a lifemap_obj object.
lm_piecharts(
data = NULL,
param,
type = c("pie", "bar", "polar-area", "polar-radius", "auto"),
width = 30,
height = 30,
opacity = 1,
showLabels = FALSE,
pal = "Accent",
legend = TRUE,
legendPosition = c("topright", "bottomright", "bottomleft", "topleft"),
display = c("auto", "requested", "all", "leaves")
)
data |
A sub dataset to use, if NULL then all of the taxids from the lifemap object given to lifemap() will be used. |
param |
A column name indicating the discret variable to be represented. |
type |
The type of chart to draw. |
width |
The maximal width of the charts. |
height |
The maximal height of the charts. |
opacity |
The chart's opacity. |
showLabels |
A boolean indicating whether to display the values directly on the chart or not. |
pal |
The palette to be used for the charts. |
legend |
A boolean indiacting whether to draw the legend or not. |
legendPosition |
c("topright", "bottomright", "bottomleft", "topleft"). Where should the legend be placed. |
display |
c("auto", "requested", "all", "leaves"), a string indicating how to display charts :
(WARNING : "requested", "leaves" and "auto" shouldn't be used to display more than 2000 charts as it may result in long computing time) |
An lm_piecharts object containing all aesthetics details for one layer of charts
data(LM_eukaryotes)
lm_piecharts(param = "Status")
lm_piecharts(data = LM_eukaryotes$df[LM_eukaryotes$df$Group %in% "Plants", ], param = "Status")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.