#' @importFrom utils menu
choose <- function(partial = "", answers) {
good_answers <- answers[startsWith(answers, partial)]
sel <- menu(good_answers, title = "Choose current test")
if (sel == 0) stop("No test selected")
good_answers[sel]
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.