如何在测验中为 checkboxGridItem 问题分配正确答案?
How to assign correct answers to checkboxGridItem questions in a quiz?
使用 Google 表格进行多项选择测验的一个问题是,如果一个问题有(例如)3 分和 5 个正确答案中的 3 个,如果学生只选择 3 个中的 2 个正确答案他们将获得 0 分,而不是 2 分。
解决方法是使用只有 1 列的 checkboxGrid,其中每一行都是一个答案选择。
然后可以为每个正确选择的行奖励积分。
我现在想使用这种方法即时创建修订测验,我的代码片段在这里:
var question = questions[Math.floor(Math.random() * questions.length)];
var item = tasks.addCheckboxGridItem();
item.setTitle(question[1]);
item.setRows([ question[3],question[4],question[5],question[6],question,[7],question[8],question[9] ]);
item.setColumns(['Click if correct']);
我不知道如何分配正确答案并指向特定行。我可以看到如何针对简单的多项选择题执行此操作,但不适用于此 checkBoxgrid。
问题:
GridItem and CheckboxGridItem currently don't support scoring. You cannot assign correct answers and points for these Items using Apps Script (e.g. createChoice(value, isCorrect), .setPoints(points)), nor retrieve this information (e.g. .isCorrectAnswer(), .getPoints(), .getScore()).
功能请求:
问题跟踪器中目前有一个与此相关的功能请求:
我建议您点击页面左上角的星标,以跟踪此信息并帮助确定优先顺序。
解决方法:
同时,您唯一的选择是改用 UI,或者自己编写评分函数,如参考问题中所述:
- Find your Grid Item and grab it's ItemResponse.
- Then get the response array.
- Compare it to some grading function you create.
- Return a score and use that number instead.
当然,此解决方法不会将评分系统添加到表单本身,但它是一种以编程方式处理测验点的方法。
使用 Google 表格进行多项选择测验的一个问题是,如果一个问题有(例如)3 分和 5 个正确答案中的 3 个,如果学生只选择 3 个中的 2 个正确答案他们将获得 0 分,而不是 2 分。
解决方法是使用只有 1 列的 checkboxGrid,其中每一行都是一个答案选择。 然后可以为每个正确选择的行奖励积分。
我现在想使用这种方法即时创建修订测验,我的代码片段在这里:
var question = questions[Math.floor(Math.random() * questions.length)];
var item = tasks.addCheckboxGridItem();
item.setTitle(question[1]);
item.setRows([ question[3],question[4],question[5],question[6],question,[7],question[8],question[9] ]);
item.setColumns(['Click if correct']);
我不知道如何分配正确答案并指向特定行。我可以看到如何针对简单的多项选择题执行此操作,但不适用于此 checkBoxgrid。
问题:
GridItem and CheckboxGridItem currently don't support scoring. You cannot assign correct answers and points for these Items using Apps Script (e.g. createChoice(value, isCorrect), .setPoints(points)), nor retrieve this information (e.g. .isCorrectAnswer(), .getPoints(), .getScore()).
功能请求:
问题跟踪器中目前有一个与此相关的功能请求:
我建议您点击页面左上角的星标,以跟踪此信息并帮助确定优先顺序。
解决方法:
同时,您唯一的选择是改用 UI,或者自己编写评分函数,如参考问题中所述:
- Find your Grid Item and grab it's ItemResponse.
- Then get the response array.
- Compare it to some grading function you create.
- Return a score and use that number instead.
当然,此解决方法不会将评分系统添加到表单本身,但它是一种以编程方式处理测验点的方法。