Added estimize stars
This commit is contained in:
parent
d9a2cb3956
commit
8fbfa86337
12
src/stars.js
12
src/stars.js
|
@ -45,6 +45,15 @@ function calculateStarsElicit(data) {
|
||||||
return starsInteger
|
return starsInteger
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function calculateStarsEstimize(data) {
|
||||||
|
let nuno = data => 2
|
||||||
|
let eli = (data) => null
|
||||||
|
let misha = (data) => null
|
||||||
|
let starsDecimal = average([nuno(data)]) //, eli(data), misha(data)])
|
||||||
|
let starsInteger = Math.round(starsDecimal)
|
||||||
|
return starsInteger
|
||||||
|
}
|
||||||
|
|
||||||
function calculateStarsForetold(data) {
|
function calculateStarsForetold(data) {
|
||||||
let nuno = data => 2
|
let nuno = data => 2
|
||||||
let eli = (data) => null
|
let eli = (data) => null
|
||||||
|
@ -169,6 +178,9 @@ export function calculateStars(platform, data) {
|
||||||
case "Elicit":
|
case "Elicit":
|
||||||
stars = calculateStarsElicit(data)
|
stars = calculateStarsElicit(data)
|
||||||
break;
|
break;
|
||||||
|
case "Estimize":
|
||||||
|
stars = calculateStarsEstimize(data)
|
||||||
|
break;
|
||||||
case "Foretold":
|
case "Foretold":
|
||||||
stars = calculateStarsForetold(data)
|
stars = calculateStarsForetold(data)
|
||||||
break;
|
break;
|
||||||
|
|
Loading…
Reference in New Issue
Block a user