| dt2_cols_render_orthogonal | R Documentation |
Supply different renderers for each orthogonal data request. Pass an
object with keys display, sort, filter, type
(all optional). Each value must be a JS function.
dt2_cols_render_orthogonal(
options = list(),
col_specs,
display = NULL,
sort = NULL,
filter = NULL,
type = NULL
)
options |
Options list to modify. |
col_specs |
Column names or indices. |
display |
Optional JS renderer for UI display. |
sort |
Optional JS renderer used for ordering. |
filter |
Optional JS renderer used for searching. |
type |
Optional JS renderer used for type detection. |
Modified options.
opts <- list(columns = names(iris))
opts <- dt2_cols_render_orthogonal(
opts, "Sepal.Length",
display = htmlwidgets::JS("function(d,t,row,meta){ return d + ' cm'; }"),
sort = htmlwidgets::JS("function(d,t,row,meta){ return parseFloat(d); }")
)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.