lc_colourSlider {rlc} | R Documentation |
Add a colour slider
Description
Colour slider provides an easy way to change any continuous colour scale interactively. If your chart uses a continuous colour scale, you can just link a colour slider and it will be automatically synchronized with your chart's colour scale.
Usage
lc_colourSlider(data = list(), place = NULL, ..., chartId = NULL, with = NULL)
Arguments
data |
Name-value pairs of properties passed through the |
place |
An ID of the container, where to place new chart. It will be ignored if the chart already exists. If not defined, the chart will be appended to the web page's body. |
... |
Name-value pairs of properties that will be evaluated only once and then will remain
constant. These properties can still be changed later using the |
chartId |
An ID for the chart. All charts must have unique IDs. If a chart with the same ID already
exists, it will be replaced. If ID is not defined, it will be the same as the
value of the |
with |
A dataset or a list from which other properties should be taken. If the dataset doesn't have a
column with the requested name, the variable will be searched for outside of the dataset. Must be
a |
Available properties
You can read more about different properties here.
-
chart
- ID of the chart to which the colour slider should be linked. -
layer
- id of the layer to which the colour slider should be linked. If the chart has only one layer, this property is optional.
Global chart settings
-
width
- width of the chart in pixels. -
heigth
- height of the chart in pixels. -
paddings
- padding sizes in pixels. Must be a list with all the following fields:"top", "bottom", "left", "right"
. -
title
- a title of the chart. -
titleX, titleY
- coordinates of the chart title. -
titleSize
- font-size of the chart title.
Examples
## Not run: data("iris")
lc_scatter(dat(x = Sepal.Length,
y = Petal.Length,
colourValue = Petal.Width,
symbolValue = Species),
with = iris,
title = "Iris dataset",
axisTitleY = "Petal Length",
axisTitleX = "Sepal Length",
colourLegendTitle = "Petal Width",
symbolLegendTitle = "Species",
showLegend = FALSE,
chartId = "scatter")
lc_colourSlider(chart = "scatter")
## End(Not run)