data_draw | R Documentation |
This function creates data for a Highcharts plot, given input data and options.
data_draw(
data,
dic = NULL,
var_cat = NULL,
var_num = NULL,
var_date = NULL,
viz = NULL,
frType = NULL,
opts = NULL
)
data |
a data frame containing the data to be plotted |
dic |
a named vector specifying the categories and colors for the data |
var_cat |
the name of the categorical variable in the data frame |
var_num |
the name of the numeric variable in the data frame |
var_date |
the name of the date variable in the data frame |
viz |
the type of visualization to be created ("treemap", "line", "bar", "pie", or "donut") |
frType |
a string indicating the format of the data frame (e.g., "CatNum", "DatNum", "CatCatNum") |
opts |
a list containing options for the plot (e.g., tooltip_template, na_label, format_sample_num) |
a list of data for use in creating a Highcharts plot
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.