Skip to contents

Parses a rubric YAML file into the rubric list structure used by rubric_import() and write_rubric_yaml(). Item order in the file determines display order and keyboard hotkeys: the first ten items of a question get the keys 1-9 and 0, and any further items have no hotkey and are toggled by clicking in mark(). There is no limit on the number of items. A group entry in the items list (format "1.1") is flattened: its members join the question's item list in place, each with its group set, and the group itself is recorded in the question's groups. Validation is performed by the S7 constructors as items and groups are built.

Usage

read_rubric_yaml(path)

Arguments

path

Path to a rubric .yaml/.yml file.

Value

A rubric list: format_version plus questions, each with name, items (a list of markermd_rubric_item objects), groups (a named list of markermd_rubric_group objects, empty when the question has none) and scoring (a markermd_grade_state object, or NULL when the file omits it).