View source: R/check_key_vars.R
check_key_vars | R Documentation |
This function checks if specified key variables are present in each tibble's "id" column and returns only tibbles that contain all required key variables.
check_key_vars(tibble_list, key_vars, verbose = FALSE)
tibble_list |
A named list of tibbles, each containing an "id" column with question identifiers |
key_vars |
A character vector of key variables to check for |
verbose |
A logical value (TRUE or FALSE) specifying verbosity level. If TRUE, reports tibbles that are removed and why. |
A list of tibbles that contain all required key variables
## Not run:
# Create sample data
path <- file.path(find.package("tutorial.helpers"), "tests/testthat/fixtures/answers_html")
tibble_list <- gather_submissions(path, "stop")
result <- check_key_vars(tibble_list,
key_vars = c("name", "email"))
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.