I want to ask, can somebody help me how to validate select input like this ? We assume that there is no factor in iris. Is there some way how to validate it ?
Server:
output$choose_y = renderUI({
is_factor <- sapply(iris, FUN = is.factor)
y_choices <- names(iris) [is_factor]
selectInput('choose_y', label = 'Choose Target Variable', choices = y_choices)
})
Ui:
uiOutput('choose_y')