Skip to content

Instantly share code, notes, and snippets.

@zappingseb
Last active July 16, 2019 21:23
Show Gist options
  • Save zappingseb/2e03d7531971386f5fd340ab3401854b to your computer and use it in GitHub Desktop.
Save zappingseb/2e03d7531971386f5fd340ab3401854b to your computer and use it in GitHub Desktop.
formula_reactive <- reactive({
validate(need(is.character(input$select_regressor), "Cannot work without selected column"))
regressors <- Reduce(function(x, y) call("+", x, y), rlang::syms(input$select_regressor))
rlang::new_formula(rlang::sym("AVAL"), regressors)
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment