I am using exams2moodle() to create exam quizzes. I would like to use some math symbols which require the LaTeX package amssymb. How should I proce
In general, you input your symbols into either .Rmd or .Rnw and you can have it rendered with any available engine (e.g. pandoc, mathjax, knitr, etc).
install.packages("exams")
require(exams)
xWeave is called on each exercise file and creates LaTeX code
elearn_exam <- c("swisscapital.Rmd", "deriv.Rmd", "ttest.Rmd",
"boxplots.Rmd", "function.Rmd", "lm.Rmd", "fourfold2.Rmd")
set.seed(2020-04-16)
exams2moodle() produces an XML file that may be uploaded into Moodle
It goes from LaTeX to HTML then HTML to XML
exams2moodle(elearn_exam, n = 3, name = "R-exams")
To add custom LaTeX packages you can modify the preamble as per the answers in this post, i.e. \usepackage
As described in the linked post, that can either be done direct, i.e.
---
title: "Title"
author: "Me"
header-includes:
- \usepackage{mypackage}
output:
pdf_document
---
or via a mystyles.sty file in the same directory.