-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Deploying to gh-pages from @ 6cacd17 🚀
- Loading branch information
1 parent
c86d04c
commit 918d45b
Showing
3 changed files
with
4 additions
and
4 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
[{"path":"http://emitanaka.org/moodlequiz/authors.html","id":null,"dir":"","previous_headings":"","what":"Authors","title":"Authors and Citation","text":"Emi Tanaka. Author, maintainer. Mitchell O'Hara-Wild. Author.","code":""},{"path":"http://emitanaka.org/moodlequiz/authors.html","id":"citation","dir":"","previous_headings":"","what":"Citation","title":"Authors and Citation","text":"Tanaka E, O'Hara-Wild M (2023). moodlequiz: R Markdown format Moodle XML cloze quizzes. R package version 0.1.0.9001, http://emitanaka.org/moodlequiz/, https://github.com/emitanaka/moodlequiz.","code":"@Manual{, title = {moodlequiz: R Markdown format for Moodle XML cloze quizzes}, author = {Emi Tanaka and Mitchell O'Hara-Wild}, year = {2023}, note = {R package version 0.1.0.9001, http://emitanaka.org/moodlequiz/}, url = {https://github.com/emitanaka/moodlequiz}, }"},{"path":"http://emitanaka.org/moodlequiz/index.html","id":"moodlequiz","dir":"","previous_headings":"","what":"R Markdown format for Moodle XML cloze quizzes","title":"R Markdown format for Moodle XML cloze quizzes","text":"moodlequiz R package allows creation Moodle quiz questions using literate programming R Markdown. makes easy quickly create quiz can randomly replicated new datasets, questions, options answers.","code":""},{"path":"http://emitanaka.org/moodlequiz/index.html","id":"installation","dir":"","previous_headings":"","what":"Installation","title":"R Markdown format for Moodle XML cloze quizzes","text":"can install development version moodlequiz like :","code":"remotes::install_github(\"numbats/moodlequiz\")"},{"path":"http://emitanaka.org/moodlequiz/index.html","id":"example","dir":"","previous_headings":"","what":"Example","title":"R Markdown format for Moodle XML cloze quizzes","text":"Moodle quiz students select right variables data map onto plot aesthetics ggplot2. quiz created R Markdown document . Knitting document generate 5 different versions quiz x, y, color, size mapped randomly one variables mtcars data.","code":"--- output: moodlequiz::moodlequiz: replicates: 5 title: Drawing a scatterplot times: 5 moodlequiz: category: datavis-scatterplots --- # Data ```{r setup, include = FALSE} library(tidyverse) library(rlang) library(moodlequiz) knitr::opts_chunk$set(echo = FALSE, results = \"hide\", fig.height = 4, fig.width = 5, fig.path = \"\", fig.cap = \"\", fig.align = \"center\") ``` ```{r data} cols <- colnames(mtcars) cats <- c(\"cyl\", \"vs\", \"am\", \"gear\", \"carb\") nums <- setdiff(cols, cats) x <- sample(nums, 1) y <- sample(setdiff(nums, x), 1) color <- sample(cats, 1) size <- sample(setdiff(nums, c(x, y)), 1) ``` You have been asked to analyse the `mtcars` data. The variables and the class types of the data is shown below. ```{r, echo = TRUE, results = \"show\"} str(mtcars) ``` # Plot As a starting point, you decide to draw a scatter plot for some variables. Complete the code below to get the target plot below: ```r ggplot(mtcars, aes(x = `r cloze(x, cols)`, y = `r cloze(y, cols)`, color = factor(`r cloze(color, cols)`), size = `r cloze(size, cols)`)) + `r cloze(\"geom_point\", ls(envir = as.environment(\"package:ggplot2\"), pattern = \"^geom_\"))`() ``` ```{r, results = \"show\"} ggplot(mtcars, aes(!!sym(x), !!sym(y), size = !!sym(size), color = factor(!!sym(color)))) + geom_point() + theme(plot.background = element_rect(color = \"black\")) ```"},{"path":"http://emitanaka.org/moodlequiz/reference/choices.html","id":null,"dir":"Reference","previous_headings":"","what":"Create a set of choices for single or multiple choice questions — choices","title":"Create a set of choices for single or multiple choice questions — choices","text":"Create set choices single multiple choice questions","code":""},{"path":"http://emitanaka.org/moodlequiz/reference/choices.html","id":"ref-usage","dir":"Reference","previous_headings":"","what":"Usage","title":"Create a set of choices for single or multiple choice questions — choices","text":"","code":"choices(options, answer)"},{"path":"http://emitanaka.org/moodlequiz/reference/choices.html","id":"arguments","dir":"Reference","previous_headings":"","what":"Arguments","title":"Create a set of choices for single or multiple choice questions — choices","text":"character vector correct answers","code":""},{"path":"http://emitanaka.org/moodlequiz/reference/cloze.html","id":null,"dir":"Reference","previous_headings":"","what":"Succinctly create a suitable cloze question — cloze","title":"Succinctly create a suitable cloze question — cloze","text":"Succinctly create suitable cloze question","code":""},{"path":"http://emitanaka.org/moodlequiz/reference/cloze.html","id":"ref-usage","dir":"Reference","previous_headings":"","what":"Usage","title":"Succinctly create a suitable cloze question — cloze","text":"","code":"cloze(x, ...)"},{"path":"http://emitanaka.org/moodlequiz/reference/cloze.html","id":"arguments","dir":"Reference","previous_headings":"","what":"Arguments","title":"Succinctly create a suitable cloze question — cloze","text":"x correct answer ... Options passed methods","code":""},{"path":"http://emitanaka.org/moodlequiz/reference/moodlequiz.html","id":null,"dir":"Reference","previous_headings":"","what":"R Markdown format for Moodle XML quizzes — moodlequiz","title":"R Markdown format for Moodle XML quizzes — moodlequiz","text":"Provides alternative interface working exams package producing Moodle questions type.","code":""},{"path":"http://emitanaka.org/moodlequiz/reference/moodlequiz.html","id":"ref-usage","dir":"Reference","previous_headings":"","what":"Usage","title":"R Markdown format for Moodle XML quizzes — moodlequiz","text":"","code":"moodlequiz( replicates = 1L, self_contained = TRUE, extra_dependencies = NULL, theme = NULL, includes = NULL, lib_dir = NULL, md_extensions = NULL, pandoc_args = NULL, ... )"},{"path":"http://emitanaka.org/moodlequiz/reference/moodlequiz.html","id":"arguments","dir":"Reference","previous_headings":"","what":"Arguments","title":"R Markdown format for Moodle XML quizzes — moodlequiz","text":"replicates number times questions rendered, useful producing multiple versions quiz different random samples. keep identify replicates questions random importation Moodle recommend organising materials categories using top level headers. self_contained Produce standalone HTML file external dependencies, using data: URIs incorporate contents linked scripts, stylesheets, images, videos. Note even self contained documents MathJax still loaded externally (necessary size). extra_dependencies Extra dependencies list html_dependency class objects typically generated htmltools:htmlDependency(). theme One following: bslib::bs_theme() object (list bslib::bs_theme() argument values) Use option custom themes using Bootstrap 4 3. case, .scss/.sass files provided css parameter may utilize theme's underlying Sass utilities (e.g., variables, mixins, etc). NULL theme (.e., html_dependency_bootstrap()). character string specifying Bootswatch 3 theme name (backwards-compatibility). includes Named list additional content include within document (typically created using includes function). lib_dir Directory copy dependent HTML libraries (e.g. jquery, bootstrap, etc.) . default name document _files appended . md_extensions Markdown extensions added removed default definition R Markdown. See rmarkdown_format additional details. pandoc_args Additional command line options pass pandoc ... Additional function arguments pass base R Markdown HTML output formatter html_document_base","code":""},{"path":"http://emitanaka.org/moodlequiz/news/index.html","id":"moodlequiz-development-version","dir":"Changelog","previous_headings":"","what":"moodlequiz (development version)","title":"moodlequiz (development version)","text":"First major release.","code":""},{"path":"http://emitanaka.org/moodlequiz/news/index.html","id":"new-features-development-version","dir":"Changelog","previous_headings":"","what":"New features","title":"moodlequiz (development version)","text":"Added cloze() cloze_*() functionality. Added moodlequiz() output format R Markdown. Added choices() helper constructing graded vectors choices.","code":""}] | ||
[{"path":"http://emitanaka.org/moodlequiz/authors.html","id":null,"dir":"","previous_headings":"","what":"Authors","title":"Authors and Citation","text":"Emi Tanaka. Author, maintainer. Mitchell O'Hara-Wild. Author.","code":""},{"path":"http://emitanaka.org/moodlequiz/authors.html","id":"citation","dir":"","previous_headings":"","what":"Citation","title":"Authors and Citation","text":"Tanaka E, O'Hara-Wild M (2024). moodlequiz: R Markdown format Moodle XML cloze quizzes. R package version 0.1.0.9001, http://emitanaka.org/moodlequiz/, https://github.com/emitanaka/moodlequiz.","code":"@Manual{, title = {moodlequiz: R Markdown format for Moodle XML cloze quizzes}, author = {Emi Tanaka and Mitchell O'Hara-Wild}, year = {2024}, note = {R package version 0.1.0.9001, http://emitanaka.org/moodlequiz/}, url = {https://github.com/emitanaka/moodlequiz}, }"},{"path":"http://emitanaka.org/moodlequiz/index.html","id":"moodlequiz","dir":"","previous_headings":"","what":"R Markdown format for Moodle XML cloze quizzes","title":"R Markdown format for Moodle XML cloze quizzes","text":"moodlequiz R package allows creation Moodle quiz questions using literate programming R Markdown. makes easy quickly create quiz can randomly replicated new datasets, questions, options answers.","code":""},{"path":"http://emitanaka.org/moodlequiz/index.html","id":"installation","dir":"","previous_headings":"","what":"Installation","title":"R Markdown format for Moodle XML cloze quizzes","text":"can install development version moodlequiz like :","code":"remotes::install_github(\"numbats/moodlequiz\")"},{"path":"http://emitanaka.org/moodlequiz/index.html","id":"example","dir":"","previous_headings":"","what":"Example","title":"R Markdown format for Moodle XML cloze quizzes","text":"Moodle quiz students select right variables data map onto plot aesthetics ggplot2. quiz created R Markdown document . Knitting document generate 5 different versions quiz x, y, color, size mapped randomly one variables mtcars data.","code":"--- output: moodlequiz::moodlequiz: replicates: 5 title: Drawing a scatterplot times: 5 moodlequiz: category: datavis-scatterplots --- # Data ```{r setup, include = FALSE} library(tidyverse) library(rlang) library(moodlequiz) knitr::opts_chunk$set(echo = FALSE, results = \"hide\", fig.height = 4, fig.width = 5, fig.path = \"\", fig.cap = \"\", fig.align = \"center\") ``` ```{r data} cols <- colnames(mtcars) cats <- c(\"cyl\", \"vs\", \"am\", \"gear\", \"carb\") nums <- setdiff(cols, cats) x <- sample(nums, 1) y <- sample(setdiff(nums, x), 1) color <- sample(cats, 1) size <- sample(setdiff(nums, c(x, y)), 1) ``` You have been asked to analyse the `mtcars` data. The variables and the class types of the data is shown below. ```{r, echo = TRUE, results = \"show\"} str(mtcars) ``` # Plot As a starting point, you decide to draw a scatter plot for some variables. Complete the code below to get the target plot below: ```r ggplot(mtcars, aes(x = `r cloze(x, cols)`, y = `r cloze(y, cols)`, color = factor(`r cloze(color, cols)`), size = `r cloze(size, cols)`)) + `r cloze(\"geom_point\", ls(envir = as.environment(\"package:ggplot2\"), pattern = \"^geom_\"))`() ``` ```{r, results = \"show\"} ggplot(mtcars, aes(!!sym(x), !!sym(y), size = !!sym(size), color = factor(!!sym(color)))) + geom_point() + theme(plot.background = element_rect(color = \"black\")) ```"},{"path":"http://emitanaka.org/moodlequiz/reference/choices.html","id":null,"dir":"Reference","previous_headings":"","what":"Create a set of choices for single or multiple choice questions — choices","title":"Create a set of choices for single or multiple choice questions — choices","text":"Create set choices single multiple choice questions","code":""},{"path":"http://emitanaka.org/moodlequiz/reference/choices.html","id":"ref-usage","dir":"Reference","previous_headings":"","what":"Usage","title":"Create a set of choices for single or multiple choice questions — choices","text":"","code":"choices(options, answer)"},{"path":"http://emitanaka.org/moodlequiz/reference/choices.html","id":"arguments","dir":"Reference","previous_headings":"","what":"Arguments","title":"Create a set of choices for single or multiple choice questions — choices","text":"character vector correct answers","code":""},{"path":"http://emitanaka.org/moodlequiz/reference/cloze.html","id":null,"dir":"Reference","previous_headings":"","what":"Succinctly create a suitable cloze question — cloze","title":"Succinctly create a suitable cloze question — cloze","text":"Succinctly create suitable cloze question","code":""},{"path":"http://emitanaka.org/moodlequiz/reference/cloze.html","id":"ref-usage","dir":"Reference","previous_headings":"","what":"Usage","title":"Succinctly create a suitable cloze question — cloze","text":"","code":"cloze(x, ...)"},{"path":"http://emitanaka.org/moodlequiz/reference/cloze.html","id":"arguments","dir":"Reference","previous_headings":"","what":"Arguments","title":"Succinctly create a suitable cloze question — cloze","text":"x correct answer ... Options passed methods","code":""},{"path":"http://emitanaka.org/moodlequiz/reference/moodlequiz.html","id":null,"dir":"Reference","previous_headings":"","what":"R Markdown format for Moodle XML quizzes — moodlequiz","title":"R Markdown format for Moodle XML quizzes — moodlequiz","text":"Provides alternative interface working exams package producing Moodle questions type.","code":""},{"path":"http://emitanaka.org/moodlequiz/reference/moodlequiz.html","id":"ref-usage","dir":"Reference","previous_headings":"","what":"Usage","title":"R Markdown format for Moodle XML quizzes — moodlequiz","text":"","code":"moodlequiz( replicates = 1L, self_contained = TRUE, extra_dependencies = NULL, theme = NULL, includes = NULL, lib_dir = NULL, md_extensions = NULL, pandoc_args = NULL, ... )"},{"path":"http://emitanaka.org/moodlequiz/reference/moodlequiz.html","id":"arguments","dir":"Reference","previous_headings":"","what":"Arguments","title":"R Markdown format for Moodle XML quizzes — moodlequiz","text":"replicates number times questions rendered, useful producing multiple versions quiz different random samples. keep identify replicates questions random importation Moodle recommend organising materials categories using top level headers. self_contained Produce standalone HTML file external dependencies, using data: URIs incorporate contents linked scripts, stylesheets, images, videos. Note even self contained documents MathJax still loaded externally (necessary size). extra_dependencies Extra dependencies list html_dependency class objects typically generated htmltools:htmlDependency(). theme One following: bslib::bs_theme() object (list bslib::bs_theme() argument values) Use option custom themes using Bootstrap 4 3. case, .scss/.sass files provided css parameter may utilize theme's underlying Sass utilities (e.g., variables, mixins, etc). NULL theme (.e., html_dependency_bootstrap()). character string specifying Bootswatch 3 theme name (backwards-compatibility). includes Named list additional content include within document (typically created using includes function). lib_dir Directory copy dependent HTML libraries (e.g. jquery, bootstrap, etc.) . default name document _files appended . md_extensions Markdown extensions added removed default definition R Markdown. See rmarkdown_format additional details. pandoc_args Additional command line options pass pandoc ... Additional function arguments pass base R Markdown HTML output formatter html_document_base","code":""},{"path":"http://emitanaka.org/moodlequiz/news/index.html","id":"moodlequiz-development-version","dir":"Changelog","previous_headings":"","what":"moodlequiz (development version)","title":"moodlequiz (development version)","text":"First major release.","code":""},{"path":"http://emitanaka.org/moodlequiz/news/index.html","id":"new-features-development-version","dir":"Changelog","previous_headings":"","what":"New features","title":"moodlequiz (development version)","text":"Added cloze() cloze_*() functionality. Added moodlequiz() output format R Markdown. Added choices() helper constructing graded vectors choices.","code":""}] |