implement biases
This commit is contained in:
parent
9a8111224b
commit
242e119222
2 changed files with 6 additions and 3 deletions
5
rank.js
5
rank.js
|
@ -1,6 +1,6 @@
|
|||
|
||||
// derived from https://git.dervland.net/biglyderv/new-bigly-chat/src/branch/master/docs/stats.php
|
||||
function rankCalc(result, iterations = 10) {
|
||||
function rankCalc(result, iterations = 10, main = []) {
|
||||
let matrixe = {}
|
||||
let fng = {};
|
||||
let fnc = {};
|
||||
|
@ -51,6 +51,9 @@ function rankCalc(result, iterations = 10) {
|
|||
for (let una in result) {
|
||||
th++;
|
||||
pr[una] = 0.1 / rl;
|
||||
if (main.indexOf(una) != -1) {
|
||||
pr[una] = 0.5;
|
||||
}
|
||||
matrixe[una] = [];
|
||||
if (frs[una].length == 0) {
|
||||
pr[una] = prold[una];
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue