使用exams2moodle() 跨练习共享随机CSV 数据集 [英] Sharing a random CSV data set across exercises with exams2moodle()

查看:45
本文介绍了使用exams2moodle() 跨练习共享随机CSV 数据集的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想使用来自 R/exams 的 exams2moodle() 从 6 个练习模板中创建一个包含 300 个随机复制的 Moodle 测验.6 个练习模板依赖于一个数据集,该数据集是在第一个练习中从更大的数据库中随机生成的 CSV 文件.

I want to create a Moodle quiz with 300 random replications from 6 exercise templates using exams2moodle() from R/exams. The 6 exercise templates depend on a data set that is randomly generated as a CSV file from a larger data base in the first exercise.

命令 exams2pdf() 正是我想要的,但我想重现 exams2pdf()exams2moodle() 命令的作用.但是,这只会生成一个测验,其中包含 300 个类型 1、300 个类型 2、...和 ​​300 个类型 6.我不知道如何强制 Moodle 在同一个测验中结合第一个类型 1 问题第一个类型 2 问题,第一个类型 3 问题,...和第一个类型 6 问题.然后,创建的考试将与命令 exams2pdf() 生成的考试相同.

The command exams2pdf() does just what I want but I want to reproduce what exams2pdf() does with the exams2moodle() command. However, this just generates a quiz with 300 questions of type 1, 300 of type 2, ..., and 300 of type 6. I don't know how to force Moodle to combine the first type 1 question in the same quiz along with the first type 2 question, the first type 3 question, ..., and the first type 6 question. Then, the exam created would be the same one that the command exams2pdf() generates.

推荐答案

对此的简短回答是这种类型的采样目前在 Moodle 中是不可能的.您只能选择在测验中包含特定问题或从特定池中选择一个随机问题.但是(据我所知)没有办法将跨池的随机问题的选择联系起来.潜在的解决方法是:

The short answer to this is that this type of sampling is currently not possible in Moodle. You only have the option to inlcude a specific question in a quiz or to select a random question from a certain pool. But there is (to the best of my knowledge) no way of linking the selection of the random questions across pools. Potential workarounds are:

  • 您只有 10 个版本,而不是 300 个版本的测验.然后,您可以将所有 10 个测验放在一起,每个测验都有固定的问题序列.然后你需要将你的参与者分成 10 组,并将他们分配到十个测验之一.这非常乏味,但可以让您无需修改​​即可使用您的问题.
    技术说明:当使用 exams2moodle() 和 .Rmd(而不是 .Rnw)练习生成测验时,您必须设置 envir = .GlobalEnv(或其他一些环境).只有当使用 knitr 时,第一个练习中随机生成的数据才会与后续练习共享(而这是使用 Sweave() 时的唯一选项).
  • 您不必将 6 个单独的练习组合成一个 完形填空 练习.不过,这是否可行取决于 6 个任务的复杂性.如果它们太复杂,完形填空练习就会变得太长和太复杂.
  • Instead of having 300 versions of the quiz you just have, say, 10 versions. Then you can put together all 10 quizzes, each with a fixed sequence of questions. And then you need to split up your participants into 10 groups and assign them to one of the ten quizzes. This is very tedious but lets you use your questions without modification.
    Technical note: When generating the quiz with exams2moodle() with .Rmd (rather than .Rnw) exercises you have to set envir = .GlobalEnv (or some other environment). Only then the randomly-generated data from the first exercise is shared with subsequent exercises when using knitr (while this is the only option when using Sweave()).
  • Instead of having 6 separate exercises, you combine them into a single cloze exercise. Whether this is feasible, though, depends on the complexity of the 6 tasks. If they are too complex, the cloze exercise would become too long and too convoluted.

有关这些问题的更多讨论,请参阅 R-Forge 上的 R/考试论坛中的以下主题:

For some more discussion regarding these issues, see the following threads from the R/exams forum on R-Forge:

这篇关于使用exams2moodle() 跨练习共享随机CSV 数据集的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆