Fix and simplify rate calculation #15

Merged
w2 merged 1 commits from w2/photovoter_backend:rate-calculation-fix into main 4 years ago
w2 commented 4 years ago
Owner

Previously used formula

100 * SUM(marks.mark)/COUNT(marks.mark)/MAX(marks.mark)

gave wrong results.

Stabilization of frontend like/dislike representation to 1/0 allows radical simplification of rate calculation formula.

100 * AVG(marks.mark)
Previously used formula ``` 100 * SUM(marks.mark)/COUNT(marks.mark)/MAX(marks.mark) ``` gave wrong results. Stabilization of frontend like/dislike representation to 1/0 allows radical simplification of rate calculation formula. ``` 100 * AVG(marks.mark) ```
w2 added 1 commit 4 years ago
Poster
Owner

fixes #14

fixes #14
g commented 4 years ago
Owner

lgtm

lgtm
w2 requested review from g 4 years ago
w2 removed review request for g 4 years ago
w2 merged commit a5b1da352a into main 4 years ago
w2 deleted branch rate-calculation-fix 4 years ago
The pull request has been merged as a5b1da352a.
Sign in to join this conversation.
No reviewers
No Label
No Milestone
No project
No Assignees
2 Participants
Notifications
Due Date

No due date set.

Dependencies

No dependencies set.

Reference: DIWHY/photovoter_backend#15
Loading…
There is no content yet.