pivot_rate_module: The server function for a pivot table module

Description Usage Arguments Value Examples

Description

This function should be passed to callModule. See example.

Usage

1
2
pivot_rate_module(input, output, session, ns_id, numer_df, denom_df,
  pivot_vars, record_limit = 1e+06, show_filter_text = T)

Arguments

input

A standard argument used by shiny when creating the module.

output

A standard argument used by shiny when creating the module.

session

A standard argument used by shiny when creating the module.

ns_id

The module namespace id as a string. Must match a namespace id of the corresponding UI module element.

pivot_vars

A table constructed using the get_pivot_vars function.

record_limit

The maximum number of rows to bring into R to display. This is a saftely measure. You probably don't want to bring 100 million rows of data into R from a database. Defaults to 1 million.

df

A local dataframe/tibble or tbl_dbi database connection object.

Value

The server function needed for a pivot table module.

Examples

1
2
3
4
 # note that the namespace id must
server <- function(input, output, session){
   callModule(pivot_module, id = "id1", ns_id = "id1", df = df1, pivot_vars = pivot_vars1, record_limit = 20)
}

ablack3/shinyPivot documentation built on Aug. 25, 2019, 2:35 p.m.