Create a select list input control
Create a select list that can be used to choose a single or multiple items from a list of values.
selectInput(inputId, label, choices, selected = NULL, multiple = FALSE)
- Input variable to assign the control's value to
- Display label for the control
- List of values to select from. If elements of the list are named then that name rather than the value is displayed to the user.
- Name of initially selected item (or
multiple names if
multiple = TRUE). If not specified then defaults to the first item for single-select lists and no items for multiple select lists.
- Is selection of multiple items allowed?
- A select list control that can be added to a UI definition.
selectInput("variable", "Variable:", c("Cylinders" = "cyl", "Transmission" = "am", "Gears" = "gear"))
Looks like there are no examples yet.