mdl_hotpot_attempts and calculation of grades

mdl_hotpot_attempts and calculation of grades

by B.Mich Sad -
Number of replies: 3
Hi all,
I'm trying to do some modifications on hotpot quiz system for a mini-research.

But I got stucked at a point where the hot pot question attempts are recorded.

I've seen that number of attempts and 'score' the student gets from a question differs.

Is there a known calculation method/any php function which effects the 'score' field ?

or Can I find any text description of the fields taken place in related table ?

Thanks,
Average of ratings: -
In reply to B.Mich Sad

Re: mdl_hotpot_attempts and calculation of grades

by Gordon Bateson -
Picture of Core developers Picture of Peer reviewers Picture of Plugin developers
Hi,
the score field in the hotpot_attempts table just holds the score returned from the quiz. If you want to change the score calculations, I suggest you modify the JavaScript of the quiz when it is in the browser, rather than changing PHP scripts on the server.

What knd of changes are you trying to make to the scoring of what kind of quiz?
In reply to B.Mich Sad

Re: mdl_hotpot_attempts and calculation of grades

by B.Mich Sad -
Hi,
First of all thanks for your fast reply.

The problem is : the user score in the related field seems to be cumulative.
I mean : the number of attempts are having an affect on the score written to the field or so.
I've seen students who scored 100, 75, 81 etc. and I can't get how these numbers are calculated, I need to find it out (:

I also need the score for each attempt by the user, doing that will give me a chance to change the way I am uploading course notes on Moodle etc.

In reply to B.Mich Sad

Re: mdl_hotpot_attempts and calculation of grades

by Gordon Bateson -
Picture of Core developers Picture of Peer reviewers Picture of Plugin developers

Hello again,
as you may know the scores for individual attempts at HotPot activities are combined in one of 4 ways to get the grade for the HotPot activity:

  • average of the scores of the attempts
  • maximum of the scores of the attempts
  • the score of the most recent attempt
  • the score of the oldest attempt

Which method is used depends on the setting of "grademethod" field which is set on the page where you add or update a HotPot activity.

The calculation of the HotPot grade is initiated by by the "hotpot_get_grades()" function in "mod/hotpot/lib.php". The calculation is actually done by MySQL, extracted from the MySQL results by the hotpot_get_grades() function and passed back to Moodle's core functions which then store the grade in Moodle's grade tables. 

HTH
Gordon