CSC/ECE 517 Spring 2018 E1807 bronze score calculation

From Expertiza_Wiki
Jump to navigation Jump to search

Introduction

Expertiza is an open source project based on Ruby on Rails framework. Expertiza allows the instructor to create new courses, assignments and customize new or existing assignments. It also allows the instructor to create a list of topics the students can sign up for. Students can use the expertiza platform to form teams to work on various assignments/projects. Students can sign up for various OSS topics to work on, peer review other students submission. Students can submit their assignment in the form of URLs, upload files.

Login Instructions

  • For Instructor, username: instructor6, password: password
  • For Student, username: student7490, password: password
  • For Student, username: student7495, password: password

Problem Statement

Sometimes when a reviewer fills out a review rubric, one or more fields can be left empty by the reviewer. While calculating the peer-reviewed score, the program is counting the empty fields as zero. However, this is not correct. The empty fields should not be counted at all, as this may affect some other metrics (like average score) of the reviewee.

Solution

Explanation

While calculating the peer-reviewed score, the program checks whether the score is empty or not. If a score is empty, it should not be counted while calculating average score. Only not null review scores are to be counted while dividing by the total number of reviews, for the average score calculation.

GitHub links

GitHub link

Pull Request link

Our Work

File Modified

/app/models/vm_question_response_row.rb

Explanation

The method ‘average_score_for_row’ is used to calculate the average peer-reviewed score. We added a variable ‘no_of_columns’ to count the number of review scores that are not null. We changed the way the average score is calculated. Previously, ‘row_average_score’ was calculated by dividing by ‘@score_row.length’, where the length will include both null and not null values. Now we divide ‘row_average_score’ by ‘no_of_columns’, which does not include null scores.

Testing

File Added

/spec/models/vm_question_response_row_spec.rb

Explanation

We added a RSpec file for the class ‘VmQuestionResponseRow’ to test the method ‘average_score_for_row’. We tested the following scenarios for calculating average score:

  • All scores are not null and not zero
  • All scores are not null and have some zeroes
  • All scores are not null and are all zeroes
  • Some scores are null and some scores are not null, not zero
  • Some scores are null and some scores are not null, have some zeroes
  • Some scores are null and some scores are not null, are all zeroes
  • All scores are null

Screencast

References

Expertiza

Expertiza Github

Expertiza Documentation

RSpec Documentation