Skip to contents

Specify a "numeric" input box

Usage

input_number(name, label = name, active = TRUE, min = NULL, max = NULL)

Arguments

name

Name of the input.

label

Description of the input.

active

Should the input be active by default?

min

Optional minimum value to allow in the input.

max

Optional maximum value to allow in the input.

See also

Examples

library(ggplot2)
library(dplyr)

panel_dat <- (
  ggplot(gap, aes(year, life_exp)) +
    geom_point() +
    facet_panels(vars(country, continent))
  ) |>
  as_panels_df()

trell <- panel_dat |>
as_trelliscope_df() |>
add_inputs(
  input_number(
    name = "Numeric Input",
    label = "A space to add custom ranking for sorting",
    min = 0, max = 10
  )
)
if (FALSE) { # \dontrun{
view_trelliscope(trell)
} # }