xowf::test_item::Answer_manager method exam_results (public)

 <instance of xowf::test_item::Answer_manager[i]> exam_results \
    [ -manual_gradings manual_gradings ] \
    [ -gradingScheme gradingScheme ] [ -only_grades on|off ] \
    [ -reply ] [ -format format ] [ -orderby orderby ] results_dict

Defined in packages/xowf/tcl/test-item-procs.tcl

Return results either as HTML table, as HTML chart or as csv. When "reply" is set. the result is returned directly to the browser (for downloading). When "gradingScheme" is empty, this method returns the following fields: participant, question, achieved_points, achievable points, comment When the "gradingScheme" is specified the results are per-participant. In this cases, when the "gradingScheme" is "....::none", the fields are participant, achieved, percentage otherwise the grade and rounding of achieved points and percentage are exported based on the rules of the grading scheme. participant, achieved, percentage, grade When additionally "only_grades" is specified, just participant and grad are returned/exported.

Switches:
-manual_gradings (optional)
-gradingScheme (optional)
needed for reporting grades, can be empty
-only_grades (optional, boolean, defaults to "false")
-reply (optional, defaults to "false")
when false, csv will be returned as text, when true, it will be returned as response to the browser.
-format (optional, defaults to "csv")
-orderby (optional, defaults to "participant,desc")
Parameters:
results_dict (required)
the results to format as csv, every key in the dict represents a user_id.
Returns:
csv as value or as response to the client

Testcases:
No testcase defined.
[ show source ]
Show another procedure: