dat {rlc}R Documentation

Link data to the chart

Description

dat allows linking variables from the current environment to chart's properties. On every updateCharts call, all the data provided via the dat function will be automatically re-evaluated, and the chart will be changed accordingly. One can also put properties outside of the dat function to prevent their re-evaluation. It can also be used to ensure re-evaluation of the with argument of any plotting function.

Usage

dat(...)

Arguments

...

List of name-value pairs to define the properties.

Examples

## Not run: lc_scatter(dat(x = rnorm(30)), y = rnorm(30))
#note that the Y values remain the same after each updateCharts call
updateCharts()

#This way the dataset is not strored inside the chart and will be re-evaluated
data("iris")
lc_scatter(dat(x = Sepal.Length, y = Petal.Length), with = dat(iris))

iris <- iris[1:10, ]
updateCharts()

## End(Not run)


[Package rlc version 0.5.0 Index]