Discrimination index under Moodle quiz

Re: Ynt: Re: Discrimination index under Moodle quiz

by Tim Hunt -
Number of replies: 0
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers

When the statistics calculations were first implemented a long time ago, one of my colleagues tested them very carefully.

Also, Moodle is open source. If you really want to know what is going on, you can read the code and check it. It's not the easiest code to follow (because it was written with an eye to efficiency of the calculation as well as clarity) but this seems to be where it computes the discrimination index: https://github.com/moodle/moodle/blob/87afa4d7595eeafdf9e3f83d53272ee61fb66780/question/classes/statistics/questions/calculator.php#L415

The key difference you can get with calculations of discrimination index is whether you are computing the covariance between

  • the mark for this question and the total for all questions, or
  • the mark for this question and the total for the other questions that are not this one.

Moodle uses the second options (if my memory is right). That bit of code seems to be here: https://github.com/moodle/moodle/blob/87afa4d7595eeafdf9e3f83d53272ee61fb66780/question/classes/statistics/questions/calculator.php#L387