faster-median
TypeScript icon, indicating that this package has built-in type declarations

1.0.0 • Public • Published

faster-median

🔥 A Quick Way to get the Median Value of an Array of Numbers (Typed or Untyped)

install

npm install faster-median

usage

const fasterMedian = require("faster-median");

const nums = [0, 56, 123, 63, 763, ...];
fasterMedian({ nums, no_data: 0 })
128.1231236542

// calculate median with infinite precision using preciso
fasterMedian({ nums, no_data: 0, precise: true })
"128.1231236542451283153614234128736127354564"

Package Sidebar

Install

npm i faster-median

Weekly Downloads

986

Version

1.0.0

License

CC0-1.0

Unpacked Size

12.9 kB

Total Files

9

Last publish

Collaborators

  • danieljdufour