wq_script {swirlify} | R Documentation |
Template for R script question
Description
Template for R script question
Usage
wq_script(output = "explain what the user must do here",
answer_tests = "custom_test_name()", hint = "hint",
script = "script-name.R")
Arguments
output |
Text that is displayed to the user. |
answer_tests |
An internal function from |
hint |
A string that is printed to the console if the user answers this question incorrectly. |
script |
The name of the script template to be opened. This template
should be in a directory called |
Examples
## Not run:
# While writing a new lesson by hand just use:
wq_script()
# If converting from another format to a swirl course you may want to sue the
# API:
wq_script("Write a function that adds three numbers.",
"add_three_test()", "Something like: add3 <- function(x, y, z){x+y+z}",
"add-three.R")
## End(Not run)
[Package swirlify version 0.5.3 Index]