pimpimmi / LibreAlarm

https://plus.google.com/communities/118306966582165178782
GNU General Public License v3.0
53 stars 48 forks source link

Wrong calculation of success rate #34

Open YPOC opened 6 years ago

YPOC commented 6 years ago

The succes rate is calculated incorrectly: It uses the formula (successes - failures) / successes and therefore can reach negative values. The correct formula would be successes / (successes + failures) which will result in a number between 0 and 1