使用exam.tex通过exams2pdf生成PDF时,如何移除卷首答案列表?
移除exams2pdf生成PDF的卷首答案列表
问题背景
使用exams2pdf生成考试PDF时,卷首自动生成了答案列表,但已在题目选项旁添加勾选框,允许学生直接在题目旁标记答案,无需保留该卷首列表。
解决方案
在exams2pdf函数中添加answerlist = FALSE参数即可禁用卷首答案列表——该参数默认值为TRUE(会自动生成答案列表),设置为FALSE就能关闭此功能。
修改后的代码示例
exams2pdf(list( "boxplots.Rmd", c("tstat.Rmd", "ttest.Rmd", "confint.Rmd"), c("regression.Rmd", "anova.Rmd"), "scatterplot.Rmd", "relfreq.Rmd" ), template = c("templates/exam.tex", "templates/solution.tex"), answerlist = FALSE # 禁用卷首答案列表 )
内容的提问来源于stack exchange,提问作者guyabel
相关产品推荐
相关产品推荐

