question.numeric: Define a question that allows the selection of numeric...

Description Usage Arguments See Also

View source: R/question.R

Description

question.numeric returns a question definition that uses an input line with a spinner or a slider control for entry of numeric values.

Usage

1
2
question.numeric(id, label, min, max, step = NA, required = TRUE,
  use.slider = FALSE, width = NULL)

Arguments

id

(character) the unique identifier of the question; it will be used as the column name in the data.frame returning the questionnaire data and when prefixed with 'question' - as the inputId for the input slot.

label

(character) the text displayed as the header of the question.

min

(numeric) minimum allowed value.

max

(numeric) maximum allowed value.

step

(numeric) interval to use when stepping between min and max.

required

(logical) if FALSE, the respondent is free to not choose a response; if TRUE, the respondent must select a response before moving on to subsequent pages of the questionnaire. If use.slider == TRUE, this argument will be ignored.

use.slider

(logical) if FALSE, displays an input line with a spinner to increase/decrease the value; if TRUE, displays a slider control.

width

(character) the width of the input, e.g. '400px' or '100%'.

See Also

numericInput, sliderInput.

Other question definitions: question.mixed, question.multiple, question.single, question.text


mtrybulec/interviewer documentation built on May 23, 2019, 8:20 a.m.