generate new test that did already exist & update all module snippets with declaration
This commit is contained in:
@ -1,4 +1,4 @@
|
||||
module.exports = (arr, usePopulation = false) => {
|
||||
module.exports = standardDeviation = (arr, usePopulation = false) => {
|
||||
const mean = arr.reduce((acc, val) => acc + val, 0) / arr.length;
|
||||
return Math.sqrt(
|
||||
arr.reduce((acc, val) => acc.concat((val - mean) ** 2), []).reduce((acc, val) => acc + val, 0) /
|
||||
|
||||
Reference in New Issue
Block a user